[FIX] web: traceback when exporting from list view
Former code of list controller used the searchView of its parent,
which was the ViewManager. However, this has been changed by rev.
32b8cec53, where the ViewManager was removed, and the list
controller now has the reference of the searchView, so this code
had to be adapted. Tests have been adapted accordingly as well.
This commit is contained in:
committed by
Aaron Bohy
parent
6c211376f0
commit
33d43c5af1
@@ -64,8 +64,7 @@ var ListController = BasicController.extend({
|
||||
// TODO: this method should be synchronous...
|
||||
var self = this;
|
||||
if (this.$('thead .o_list_record_selector input').prop('checked')) {
|
||||
var searchView = this.getParent().searchview; // fixme
|
||||
var searchData = searchView.build_search_data();
|
||||
var searchData = this.searchView.build_search_data();
|
||||
var userContext = this.getSession().user_context;
|
||||
var results = pyeval.eval_domains_and_contexts({
|
||||
domains: searchData.domains,
|
||||
|
||||
@@ -94,7 +94,7 @@ QUnit.module('widgets', {
|
||||
},
|
||||
});
|
||||
|
||||
list.getParent().searchview = {
|
||||
list.searchView = {
|
||||
build_search_data: function () {
|
||||
assert.step('build_search_data');
|
||||
return {
|
||||
@@ -171,7 +171,7 @@ QUnit.module('widgets', {
|
||||
},
|
||||
});
|
||||
|
||||
list.getParent().searchview = {
|
||||
list.searchView = {
|
||||
build_search_data: function () {
|
||||
assert.step('build_search_data');
|
||||
return {
|
||||
|
||||
Reference in New Issue
Block a user