[FIX] Avoid creating sidebar each time the list view reloads itself

bzr revid: fme@openerp.com-20110808163900-qxowalfph0xeypmg
This commit is contained in:
Fabien Meghazi 2011-08-08 18:39:00 +02:00
parent 6322a565f5
commit 1a9e157eb5
1 changed files with 1 additions and 1 deletions

View File

@ -264,7 +264,7 @@ openerp.base.ListView = openerp.base.View.extend( /** @lends openerp.base.ListVi
})
.val(self._limit || 'NaN');
});
if (this.options.sidebar && this.options.sidebar_id) {
if (!this.sidebar && this.options.sidebar && this.options.sidebar_id) {
this.sidebar = new openerp.base.Sidebar(this, this.options.sidebar_id);
this.sidebar.start();
this.sidebar.add_toolbar(data.fields_view.toolbar);