From 7cdb2baea011b7bc57c5733e9ea3e9a59a774337 Mon Sep 17 00:00:00 2001 From: David Gustafsson Date: Mon, 14 Jan 2019 15:59:55 +0100 Subject: [PATCH] Bug 20589: Exclude boolean fields from search fields --- Koha/SearchEngine/Elasticsearch/QueryBuilder.pm | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Koha/SearchEngine/Elasticsearch/QueryBuilder.pm b/Koha/SearchEngine/Elasticsearch/QueryBuilder.pm index 75e6ef782f..53cbdc36a5 100644 --- a/Koha/SearchEngine/Elasticsearch/QueryBuilder.pm +++ b/Koha/SearchEngine/Elasticsearch/QueryBuilder.pm @@ -80,7 +80,6 @@ sub build_query { my $stemming = C4::Context->preference("QueryStemming") || 0; my $auto_truncation = C4::Context->preference("QueryAutoTruncate") || 0; - my $weight_fields = C4::Context->preference("QueryWeightFields") || 0; my $fuzzy_enabled = C4::Context->preference("QueryFuzzy") || 0; $query = '*' unless defined $query; @@ -1065,6 +1064,7 @@ sub _search_fields { ) : ( 'staff_client' => 1 ), + 'type' => { '!=' => 'boolean' }, 'search_marc_map.index_name' => $self->index, 'search_marc_map.marc_type' => C4::Context->preference('marcflavour'), 'search_marc_to_fields.search' => 1, -- 2.11.0