https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=36947 --- Comment #33 from David Cook <dcook@prosentient.com.au> --- (In reply to Lari Strand from comment #32)
This seems to achieve the same result as use locale (when LC_COLLATE is set to "fi_FI"):
if( C4::Context->preference('FacetOrder') eq 'Alphabetical' ){ my $coll = Unicode::Collate::Locale->new( locale => "fi_FI" ); @{ $facet->{facets} } = sort { $coll->cmp ($a->{facet_label_value}, $b->{facet_label_value}) } @{ $facet->{facets} }; } push @facets, $facet if exists $facet->{facets};
That's the idea :)
Should the collator be configurable in Koha or were you thinking of using the selected UI language for sorting somehow here?
My patch uses the system's LC_COLLATE for now, but in future it could easily use the selected UI language yeah. -- You are receiving this mail because: You are watching all bug changes.