[ADD] retain currently activated view

bzr revid: fme@openerp.com-20110331122522-3v7coio2wpnzsszn
This commit is contained in:
Fabien Meghazi 2011-03-31 14:25:22 +02:00
parent 3180df7f6c
commit 7fed892684
1 changed files with 2 additions and 0 deletions

View File

@ -35,12 +35,14 @@ openerp.base.ViewManager = openerp.base.Controller.extend({
this.searchview_id = false;
this.searchview = null;
this.search_visible = true;
this.active_view = null;
// this.views = { "list": { "view_id":1234, "controller": instance} }
this.views = {};
},
start: function() {
},
on_mode_switch: function(view_type) {
this.active_view = view_type;
for (var i in this.views) {
this.views[i].controller.$element.toggle(i === view_type);
}