@@ -, +, @@ behaviour - Just verify the behaviour remains unchanged by this patchset on the --- acqui/basketheader.pl | 5 ++++- acqui/booksellers.pl | 4 +++- acqui/invoices.pl | 2 +- acqui/transferorder.pl | 4 +++- serials/acqui-search-result.pl | 4 +++- 5 files changed, 14 insertions(+), 5 deletions(-) --- a/acqui/basketheader.pl +++ a/acqui/basketheader.pl @@ -110,7 +110,10 @@ if ( $op eq 'add_form' ) { $template->param(contractloop => \@contractloop, basketcontractnumber => $basket->{'contractnumber'}); } - my @booksellers = Koha::Acquisition::Booksellers->search; + my @booksellers = Koha::Acquisition::Booksellers->search( + undef, + { order_by => { -asc => 'name' } } ); + $template->param( add_form => 1, basketname => $basket->{'basketname'}, basketnote => $basket->{'note'}, --- a/acqui/booksellers.pl +++ a/acqui/booksellers.pl @@ -85,7 +85,9 @@ my @suppliers; if ($booksellerid) { push @suppliers, scalar Koha::Acquisition::Booksellers->find( $booksellerid ); } else { - @suppliers = Koha::Acquisition::Booksellers->search({ name => $supplier }); + @suppliers = Koha::Acquisition::Booksellers->search( + { name => { -like => "%$supplier%" } }, + { order_by => { -asc => 'name' } } ); } my $supplier_count = @suppliers; --- a/acqui/invoices.pl +++ a/acqui/invoices.pl @@ -90,7 +90,7 @@ if ( $op and $op eq 'do_search' ) { } # Build suppliers list -my @suppliers = Koha::Acquisition::Booksellers->search; +my @suppliers = Koha::Acquisition::Booksellers->search( undef, { order_by => { -asc => 'name' } } ); my $suppliers_loop = []; my $suppliername; foreach (@suppliers) { --- a/acqui/transferorder.pl +++ a/acqui/transferorder.pl @@ -117,7 +117,9 @@ if( $basketno && $ordernumber) { # Search for booksellers to transfer from/to $op = '' unless $op; if( $op eq "do_search" ) { - my @booksellers = Koha::Acquisition::Booksellers->search({ name => $query }); + my @booksellers = Koha::Acquisition::Booksellers->search( + { name => { -like => "%$query%" } }, + { order_by => { -asc => 'name' } } ); $template->param( query => $query, do_search => 1, --- a/serials/acqui-search-result.pl +++ a/serials/acqui-search-result.pl @@ -62,7 +62,9 @@ my ($template, $loggedinuser, $cookie) }); my $supplier=$query->param('supplier'); -my @suppliers = Koha::Acquisition::Booksellers->search({ name => $supplier }); +my @suppliers = Koha::Acquisition::Booksellers->search( + { name => { -like => "%$supplier%" } }, + { order_by => { -asc => 'name' } } ); #build result page my $loop_suppliers = []; --