Koha-clms/Koha/SearchEngine
Jonathan Druart 622a68f695 Bug 27597: Remove leading colon in ES query
If we are searching on kw there is a leading colon at the beginning of
the generated query:
  kw:foo becomes :foo

Note that it only happens when there is no other terms before.

Test plan:
0. Don't apply the patch
1. Search for kw:foo
2. Notice the error
  Error: Unable to perform your search. Please try again.
and the logs say
  Failed to parse query [(:foo*)]
3. Apply the patch
4. Repeat the search and notice that you know get:
   "12 result(s) found for 'kw:foo'."

Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>

Signed-off-by: Nick Clemens <nick@bywatersolutions.com>

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
(cherry picked from commit 1ff9160a62)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
(cherry picked from commit 988e119829)

Signed-off-by: Andrew Fuerste-Henry <andrew@bywatersolutions.com>
2021-03-23 14:41:06 +00:00
..
Elasticsearch Bug 27597: Remove leading colon in ES query 2021-03-23 14:41:06 +00:00
Zebra Bug 25265: [20.05.x] Prevent double reindex of the same item in batchmod 2020-10-16 14:15:22 +00:00
Elasticsearch.pm Bug 27784: Don't parse subdivision authorities as headings 2021-03-14 19:05:20 +00:00
Indexer.pm Bug 25265: [20.05.x] Prevent double reindex of the same item in batchmod 2020-10-16 14:15:22 +00:00
QueryBuilder.pm Bug 12478: allow more granular sorting configuration 2016-04-26 20:20:08 +00:00
Search.pm Bug 22721: Remove frameworkcode parameter in GetMarcFromKohaField calls 2019-07-15 11:28:08 +01:00