Updated column icon class
authorThierry Florac <thierry.florac@onf.fr>
Fri, 26 Jan 2018 16:38:30 +0100
changeset 333 606376dc9d93
parent 332 1af2540a9cce
child 334 6b2f75e60076
Updated column icon class
src/pyams_content/component/paragraph/zmi/container.py
--- a/src/pyams_content/component/paragraph/zmi/container.py	Tue Jan 16 15:41:22 2018 +0100
+++ b/src/pyams_content/component/paragraph/zmi/container.py	Fri Jan 26 16:38:30 2018 +0100
@@ -162,12 +162,11 @@
 
     weight = 5
 
-    def get_icon(self, item):
+    def get_icon_class(self, item):
         if item.visible:
-            icon_class = 'fa-eye'
+            return self.icon_class
         else:
-            icon_class = 'fa-eye-slash text-danger'
-        return '<i class="fa fa-fw {icon_class}"></i>'.format(icon_class=icon_class)
+            return 'fa fa-fw fa-eye-slash text-danger'
 
     def renderCell(self, item):
         if self.permission and not self.request.has_permission(self.permission, context=item):