From ebe12231a4d1a3ec56b44b1929c122f4afcdba1b Mon Sep 17 00:00:00 2001 From: Fridolin Somers Date: Fri, 23 Apr 2021 11:10:15 +0200 Subject: [PATCH] Bug 28202: Pickup libraries must be sorted by name when placing hold When placing hold, the pickup libraries are not sorted by name but by code. You can see in other places : pickup_locations() calls Koha::Libraries->search with { order_by => ['branchname'] } Test plan : 1) Go to staff interface 2) Create a new libary with code 'AAA' and name 'ZZZ'. 2) Select a record 3) Begin placing hold 4) Look at list in "Pickup at:" => Without patch library 'ZZZ' is first => With patch library 'ZZZ' is last Signed-off-by: David Nind Signed-off-by: Martin Renvoize Signed-off-by: Jonathan Druart (cherry picked from commit 4a6dd5f82da1f45456b953421e699abc179a6fb9) Signed-off-by: Fridolin Somers --- Koha/Biblio.pm | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Koha/Biblio.pm b/Koha/Biblio.pm index 0e17862d20..ba670608c6 100644 --- a/Koha/Biblio.pm +++ b/Koha/Biblio.pm @@ -226,7 +226,7 @@ sub pickup_locations { } return Koha::Libraries->search( - { branchcode => { '-in' => \@pickup_locations } } ); + { branchcode => { '-in' => \@pickup_locations } }, { order_by => ['branchname'] } ); } =head3 hidden_in_opac -- 2.39.5