[view] better control wether same etype view should display title or not stable
authorSylvain Thénault <sylvain.thenault@logilab.fr>
Fri, 23 Apr 2010 15:49:23 +0200
branchstable
changeset 5392 899d93e4dbe0
parent 5391 fe3fe2b2b60a
child 5395 e0ab7433e640
[view] better control wether same etype view should display title or not
web/views/baseviews.py
--- a/web/views/baseviews.py	Fri Apr 23 14:43:16 2010 +0200
+++ b/web/views/baseviews.py	Fri Apr 23 15:49:23 2010 +0200
@@ -311,7 +311,8 @@
 
     def call(self, **kwargs):
         """display a list of entities by calling their <item_vid> view"""
-        if not 'vtitle' in self._cw.form:
+        showtitle = kwargs.pop('showtitle', not 'vtitle' in self._cw.form)
+        if showtitle:
             self.w(u'<h1>%s</h1>' % self.title)
         super(SameETypeListView, self).call(**kwargs)