From 007a733f964c469a3dbaa115077929c3fa44dd77 Mon Sep 17 00:00:00 2001 From: Nick Clemens Date: Sat, 11 Sep 2021 15:12:31 +0000 Subject: [PATCH] Bug 28847: (follow-up) Handle branch_group_limit MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit To test: 1 - Create a library group as an OPAC search group 2 - Enable OpacAddMastheadLibraryPulldown 3 - Browse to: http://localhost:8080/cgi-bin/koha/opac-search.pl?idx=&q=t&branch_group_limit=multibranchlimit-1&weight_search=1 4 - Confirm search works and returns correct results 5 - Confirm dropdown is correctly populated Signed-off-by: Joonas Kylmälä Signed-off-by: Kyle M Hall --- opac/opac-search.pl | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/opac/opac-search.pl b/opac/opac-search.pl index 2771192d37..570c97c37f 100755 --- a/opac/opac-search.pl +++ b/opac/opac-search.pl @@ -79,12 +79,13 @@ my $cgi = CGI->new; my $branch_group_limit = $cgi->param("branch_group_limit"); if ( $branch_group_limit ) { if ( $branch_group_limit =~ /^multibranchlimit-/ ) { + # branch_group_limit is deprecated, it should no longer be used # For search groups we are going to convert this branch_group_limit CGI - # parameter into a multibranchlimit CGI parameter for the purposes of + # parameter into a multibranchlimit limit CGI parameter for the purposes of # actually performing the query $cgi->param( - -name => 'multibranchlimit', - -values => substr($branch_group_limit, 17) + -name => 'limit', + -values => 'multibranchlimit:' . substr($branch_group_limit, 17) ); } else { $cgi->append( -- 2.39.5