[FIX] gantt so it goes through DataSetSearch instead of calling search_read directly
bzr revid: xmo@openerp.com-20110622105920-gl0dyx8tkaau0qxq
This commit is contained in:
parent
a8355d54d7
commit
ec24a587a7
|
@ -262,21 +262,13 @@ init: function(view_manager, session, element_id, dataset, view_id) {
|
|||
throw "Unrecognized date/time format";
|
||||
},
|
||||
|
||||
reload_gantt: function(domain) {
|
||||
reload_gantt: function() {
|
||||
var self = this;
|
||||
var ajax = {
|
||||
url: '/base/dataset/search_read',
|
||||
async: false
|
||||
};
|
||||
this.rpc(ajax, {
|
||||
model: this.dataset.model,
|
||||
domain: self.dataset.domain,
|
||||
context :self.dataset.context
|
||||
}, function(response) {
|
||||
ganttChartControl.clearAll();
|
||||
jQuery("#GanttDiv").children().remove();
|
||||
self.load_event(response);
|
||||
});
|
||||
this.dataset.read_slice(false, false, false, function(response) {
|
||||
ganttChartControl.clearAll();
|
||||
jQuery("#GanttDiv").children().remove();
|
||||
self.load_event(response);
|
||||
});
|
||||
},
|
||||
|
||||
do_search: function (domains, contexts, groupbys) {
|
||||
|
@ -290,7 +282,7 @@ init: function(view_manager, session, element_id, dataset, view_id) {
|
|||
}, function (results) {
|
||||
self.dataset.context = results.context;
|
||||
self.dataset.domain = results.domain;
|
||||
return self.reload_gantt(self.dataset.domain);
|
||||
self.reload_gantt();
|
||||
});
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue