Commit 8b8f7aacf98b630f37e197db71c463e0d3511901
1 parent
a5318bd6
Exists in
elasticsearch_api
Adding visible filter
Showing
1 changed file
with
6 additions
and
2 deletions
Show diff stats
plugins/elasticsearch/controllers/elasticsearch_plugin_controller.rb
... | ... | @@ -37,9 +37,13 @@ class ElasticsearchPluginController < ApplicationController |
37 | 37 | query: { |
38 | 38 | multi_match: { |
39 | 39 | query: text, |
40 | - fields: fields | |
40 | + fields: fields, | |
41 | + operator: "and" | |
41 | 42 | } |
42 | - } | |
43 | + }, | |
44 | + filter: { | |
45 | + term: {visible: "true"} | |
46 | + } | |
43 | 47 | } |
44 | 48 | end |
45 | 49 | query | ... | ... |