--- a/web/views/baseviews.py Wed Feb 18 15:17:28 2009 +0100
+++ b/web/views/baseviews.py Wed Feb 18 15:18:47 2009 +0100
@@ -443,19 +443,6 @@
self.w(u'<a href="%s">' % self.entity(row, col).absolute_url())
self.w(html_escape(self.view('textoutofcontext', self.rset, row=row, col=col)))
self.w(u'</a>')
-
-class NotClickableInContextView(EntityView):
- id = 'incontext'
-
- def cell_call(self, row, col):
- self.w(html_escape(self.view('textincontext', self.rset, row=row, col=col)))
-
-## class NotClickableOutOfContextView(EntityView):
-## id = 'outofcontext'
-
-## def cell_call(self, row, col):
-## self.w(html_escape(self.view('textoutofcontext', self.rset, row=row)))
-
# list and table related views ################################################
--- a/web/views/wfentities.py Wed Feb 18 15:17:28 2009 +0100
+++ b/web/views/wfentities.py Wed Feb 18 15:18:47 2009 +0100
@@ -1,7 +1,7 @@
"""html view for workflow related entities
:organization: Logilab
-:copyright: 2001-2008 LOGILAB S.A. (Paris, FRANCE), all rights reserved.
+:copyright: 2001-2009 LOGILAB S.A. (Paris, FRANCE), all rights reserved.
:contact: http://www.logilab.fr/ -- mailto:contact@logilab.fr
"""
__docformat__ = "restructuredtext en"
@@ -16,3 +16,14 @@
def cell_call(self, row, col, cellvid=None):
entity = self.entity(row, col)
self.w(entity.printable_value('comment'))
+
+
+class StateInContextView(EntityView):
+ """convenience trick, State's incontext view should not be clickable"""
+ id = 'incontext'
+ __select__ = implements('State')
+
+ def cell_call(self, row, col):
+ self.w(html_escape(self.view('textincontext', self.rset,
+ row=row, col=col)))
+