[Koha-bugs] [Bug 33594] Sorting results by Title A-Z might use wrong title field
bugzilla-daemon at bugs.koha-community.org
bugzilla-daemon at bugs.koha-community.org
Mon Apr 24 09:32:00 CEST 2023
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=33594
--- Comment #1 from Janusz Kaczmarek <januszop at gmail.com> ---
I have encountered this some time ago. For me worked customizing the
mappings.yaml as follows:
- facet: ''
marc_field: 240
marc_type: marc21
- sort: ~
+ sort: ''
suggestible: ''
I.e. changing ~ into '' for all MARC fields except 245.
For some to-me-mysterious reason, ~ (= undef) is explicitly interpreted as
"yes, include it into the sort search field" by
Koha/SearchEngine/Elasticsearch.pm:
# Sort is a bit special as it can be true, false, undef.
# We care about "true" or "undef",
# "undef" means to do the default thing, which is make it
sortable.
So, since this is by design and mappings.yaml is configurable, I didn't treat
it as a bug. Just use a customized copy of mappings.
Please, check if changing ~ into '' works for you. Please, consider also if it
is worth to be a bug. If so, the solution is there.
--
You are receiving this mail because:
You are watching all bug changes.
You are the assignee for the bug.
More information about the Koha-bugs
mailing list