summaryrefslogtreecommitdiff
path: root/addons/web/static/src/xml/base.xml
diff options
context:
space:
mode:
authorLeonardo Donelli <learts92@gmail.com>2015-03-11 15:05:13 +0100
committerqsm-odoo <qsm@odoo.com>2015-12-28 11:03:50 +0100
commitb3f3c67eea0168235cec5c4246f9720286ced7dc (patch)
treec466bbcc2a34edd6b8ece59a9d7a4d065913cf20 /addons/web/static/src/xml/base.xml
parent8fe876cae712d5cdbb1f3750a5f32d22172bd392 (diff)
[FIX] web: hiding of o2m view manager header
One2many fields bring in the entire viewmanager widget. When there is only one view though (e.g. only kanban view for contact tab of partners), we want to hide the viewmanager header because we don't need it (it's where the view switcher would go). Odoo had the widget logic to do that, but it was wrongly implemented, resulting in a always present oe_view_manager_header div with all its elements (although empty). The wrong javascript operation should have triggered a client error when loading the view, but for pure chance it didn't because the t-jquery selector was wrong too so the javascript was never evaluated.
Diffstat (limited to 'addons/web/static/src/xml/base.xml')
-rw-r--r--addons/web/static/src/xml/base.xml4
1 files changed, 2 insertions, 2 deletions
diff --git a/addons/web/static/src/xml/base.xml b/addons/web/static/src/xml/base.xml
index 1f22adace16..c420fc51f4c 100644
--- a/addons/web/static/src/xml/base.xml
+++ b/addons/web/static/src/xml/base.xml
@@ -1539,8 +1539,8 @@
</t>
<t t-name="One2Many.viewmanager" t-extend="ViewManager">
- <t t-jquery=".oe-view-manager-header">
- this.attr('t-if', 'views.length != 1');
+ <t t-jquery=".oe_view_manager_header">
+ this.attr('t-if', 'widget.views_src.length != 1');
</t>
</t>
<t t-name="One2Many.formview" t-extend="FormView">