[IMP] Hide Sidebar section when item list is empty
bzr revid: fme@openerp.com-20120607144935-csiijcfoir2z362o
This commit is contained in:
parent
a6a4f8e752
commit
55bbd5f290
|
@ -743,6 +743,11 @@ instance.web.Sidebar = instance.web.Widget.extend({
|
|||
var self = this;
|
||||
self.$element.html(QWeb.render('Sidebar', {widget: self}));
|
||||
this.$element.find('ul').hide();
|
||||
|
||||
// Hides Sidebar sections when item list is empty
|
||||
this.$('.oe_form_dropdown_section').each(function() {
|
||||
$(this).toggle(!!$(this).find('li').length);
|
||||
});
|
||||
},
|
||||
/**
|
||||
* For each item added to the section:
|
||||
|
|
Loading…
Reference in New Issue