[FIX] web: m2o search facet do no set `default_*` context key for "name_search" values
This commit is contained in:
parent
9b670049b6
commit
5f47fc84e9
|
@ -1699,7 +1699,10 @@ instance.web.search.ManyToOneField = instance.web.search.CharField.extend({
|
||||||
var values = facet.values;
|
var values = facet.values;
|
||||||
if (_.isEmpty(this.attrs.context) && values.length === 1) {
|
if (_.isEmpty(this.attrs.context) && values.length === 1) {
|
||||||
var c = {};
|
var c = {};
|
||||||
c['default_' + this.attrs.name] = values.at(0).get('value');
|
var v = values.at(0);
|
||||||
|
if (v.get('operator') !== 'ilike') {
|
||||||
|
c['default_' + this.attrs.name] = v.get('value');
|
||||||
|
}
|
||||||
return c;
|
return c;
|
||||||
}
|
}
|
||||||
return this._super(facet);
|
return this._super(facet);
|
||||||
|
|
Loading…
Reference in New Issue