[FIX] partner_autocomplete: ignored field is sent to view

The field ignored is set in javascript on company object to filter the
ones we want to show. As it is not an odoo field, it triggers a
traceback when the trigger_up 'field_changed' is called.

OPW-1921568

closes odoo/odoo#29864
This commit is contained in:
Pierre Masereel
2019-01-03 07:19:35 +00:00
parent ea301bef93
commit 52dd18b8ad
@@ -53,6 +53,9 @@ return {
odooSuggestions = _.filter(odooSuggestions, function (suggestion) {
return !suggestion.ignored;
});
_.each(odooSuggestions, function(suggestion){
delete suggestion.ignored;
});
return def.resolve(odooSuggestions);
};