[saem-devel] [PATCH 10 of 10] [prov] Fix activity table header to display 'agent' instead of 'Activities (num)'

Sylvain Thenault sylvain.thenault at logilab.fr
Tue Jan 31 09:49:15 CET 2017


# HG changeset patch
# User Sylvain Thénault <sylvain.thenault at logilab.fr>
# Date 1485812209 -3600
#      Mon Jan 30 22:36:49 2017 +0100
# Node ID b422bd11a6b05ce2c60eebbf3662e91ffe954f69
# Parent  0381e47592b71f4d5aa0a3697bdb631d2edf70cb
[prov] Fix activity table header to display 'agent' instead of 'Activities (num)'

diff --git a/cubicweb_saem_ref/views/prov.py b/cubicweb_saem_ref/views/prov.py
--- a/cubicweb_saem_ref/views/prov.py
+++ b/cubicweb_saem_ref/views/prov.py
@@ -28,10 +28,13 @@ class ActivityGeneratedView(prov.Activit
            '      E description DE, E description_format DEF, X eid %(x)s')
 
 
 class ActivityAgentColRenderer(tableview.MainEntityColRenderer):
 
+    def render_header(self, w):
+        w(self._cw.__('agent'))
+
     def render_entity(self, w, entity):
         if entity.associated_with:
             w(entity.associated_with[0].view('incontext'))
         elif entity.agent:
             w(xml_escape(entity.agent))


More information about the saem-devel mailing list