[backend/elasticsearch][xs]: auto lower case terms in term filters as ES needs them to be lowercase.
This commit is contained in:
@@ -120,7 +120,7 @@ this.recline.Backend.ElasticSearch = this.recline.Backend.ElasticSearch || {};
|
|||||||
var out = {};
|
var out = {};
|
||||||
out[filter.type] = {}
|
out[filter.type] = {}
|
||||||
if (filter.type === 'term') {
|
if (filter.type === 'term') {
|
||||||
out.term[filter.field] = filter.term;
|
out.term[filter.field] = filter.term.toLowerCase();
|
||||||
} else if (filter.type === 'geo_distance') {
|
} else if (filter.type === 'geo_distance') {
|
||||||
out.geo_distance[filter.field] = filter.point;
|
out.geo_distance[filter.field] = filter.point;
|
||||||
out.geo_distance.distance = filter.distance;
|
out.geo_distance.distance = filter.distance;
|
||||||
|
|||||||
Reference in New Issue
Block a user