]> git.koha-community.org Git - koha.git/commit
Bug 12478: Display facet terms ordered by number of occurrences
authorJonathan Druart <jonathan.druart@bugs.koha-community.org>
Mon, 5 Oct 2015 14:29:52 +0000 (15:29 +0100)
committerTomas Cohen Arazi <tomascohen@theke.io>
Tue, 26 Apr 2016 13:00:46 +0000 (10:00 -0300)
commit4c7cde08fea912ce0a239d8e575ca2f44cf14845
tree225fd08feb4de076ad200ab307072c5295da6f56
parentf5747ddc450e03eeb8ed1086d4551cc83c7901fb
Bug 12478: Display facet terms ordered by number of occurrences

By default ES returns the facet terms ordered by most used, which makes
sense.

This patch removes resort done in the scripts (catalogue/search.pl and
opac/opac-search.pl) and moves it to the module.

For Zebra it's now done in C4::Search::getRecords, and there is no
change to expect (still alphabetically).

On the Elastic search side, we could imagine to let the library define
the order of the facets. The facet terms are now sorted by most used.

To test easily this change, turn on the displayFacetCount pref.

Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
Signed-off-by: Jesse Weaver <jweaver@bywatersolutions.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
C4/Search.pm
Koha/SearchEngine/Elasticsearch/Search.pm
catalogue/search.pl
opac/opac-search.pl