[FIX] web_advanced_search: Change management of relational fields

pull/2357/head
Alexandre Díaz 2020-05-19 10:37:23 +02:00 committed by Raf Ven
parent d744ca078d
commit d2f5741a1c
1 changed files with 3 additions and 3 deletions

View File

@ -168,8 +168,8 @@ odoo.define("web_advanced_search", function(require) {
// Create dummy record with only the field the user is searching
const params = {
fieldNames: [this.field.name],
modelName: this.dataset.model,
context: this.dataset.context,
modelName: this.field.relation,
context: this.field.context,
type: "record",
viewType: "default",
fieldsInfo: {
@ -203,7 +203,7 @@ odoo.define("web_advanced_search", function(require) {
start: function() {
const result = this._super.apply(this, arguments);
// Render the initial widget
result.done($.proxy(this, "show_inputs", $("<input value='='/>")));
result.then($.proxy(this, "show_inputs", $("<input value='='/>")));
return result;
},