Bug 3580 Sort the facets categories so they don't move every search.

Signed-off-by: Paul Poulain <paul.poulain@biblibre.com>
Signed-off-by: Ian Walls <ian.walls@bywatersolutions.com>
Signed-off-by: Chris Cormack <chrisc@catalyst.net.nz>
This commit is contained in:
Frédérick Capovilla 2011-02-24 12:30:09 -05:00 committed by Chris Cormack
parent 37cf503fdf
commit 0d4ab0ecb6
1 changed files with 1 additions and 0 deletions

View File

@ -431,6 +431,7 @@ if ($facets) {
foreach my $f (@$facets) {
$f->{facets} = [ sort { uc($a->{facet_title_value}) cmp uc($b->{facet_title_value}) } @{ $f->{facets} } ];
}
@$facets = sort {$a->{expand} cmp $b->{expand}} @$facets;
}
# use Data::Dumper; print STDERR "-" x 25, "\n", Dumper($results_hashref);