web/views/tabs.py
branchtreeview-tabs
changeset 997 ee71c2ba73e6
parent 917 51d5224b1698
child 999 999198995a53
--- a/web/views/tabs.py	Mon Feb 23 19:22:59 2009 +0100
+++ b/web/views/tabs.py	Tue Mar 03 12:57:25 2009 +0100
@@ -1,7 +1,7 @@
 """base classes to handle tabbed views
 
 :organization: Logilab
-:copyright: 2008 LOGILAB S.A. (Paris, FRANCE), all rights reserved.
+:copyright: 2008-2009 LOGILAB S.A. (Paris, FRANCE), all rights reserved.
 :contact: http://www.logilab.fr/ -- mailto:contact@logilab.fr
 """
 
@@ -97,6 +97,11 @@
         self.req.add_css('ui.tabs.css')
         self.req.add_js(('ui.core.js', 'ui.tabs.js',
                          'cubicweb.ajax.js', 'cubicweb.tabs.js', 'cubicweb.lazy.js'))
+        # tabbed views do no support concatenation
+        # hence we delegate to the default tab
+        if self.req.form.get('vid') == 'primary':
+            entity.view(default)
+            return
         # prune tabs : not all are to be shown
         tabs = self.prune_tabs(tabs)
         # select a tab