From 5f47fc84e93cddac3d38239cd042c420c3ca0463 Mon Sep 17 00:00:00 2001 From: Christophe Simonis Date: Thu, 27 Nov 2014 17:04:02 +0100 Subject: [PATCH] [FIX] web: m2o search facet do no set `default_*` context key for "name_search" values --- addons/web/static/src/js/search.js | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/addons/web/static/src/js/search.js b/addons/web/static/src/js/search.js index 797bd5de3d6..eea50707035 100644 --- a/addons/web/static/src/js/search.js +++ b/addons/web/static/src/js/search.js @@ -1699,7 +1699,10 @@ instance.web.search.ManyToOneField = instance.web.search.CharField.extend({ var values = facet.values; if (_.isEmpty(this.attrs.context) && values.length === 1) { 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 this._super(facet);