From d356e71ecbc5cfb3980d4593ed490b99fe909606 Mon Sep 17 00:00:00 2001 From: Owen Leonard Date: Mon, 15 Aug 2016 14:54:16 -0400 Subject: [PATCH] Bug 13949 - Item search should have holding library This patch adds holding library ("current location") to the list of fields available in the item search form. To test, apply the patch and go to Search -> Item search. - Perform a search using the "current location" option and verify that it returns the correct results. - Try other searches to confirm that they work as before. Signed-off-by: Aleisha Amohia Signed-off-by: Jonathan Druart Signed-off-by: Kyle M Hall --- catalogue/itemsearch.pl | 2 +- .../intranet-tmpl/prog/en/modules/catalogue/itemsearch.tt | 6 ++++++ 2 files changed, 7 insertions(+), 1 deletion(-) diff --git a/catalogue/itemsearch.pl b/catalogue/itemsearch.pl index 21ee163d4c..3a5f0d95e3 100755 --- a/catalogue/itemsearch.pl +++ b/catalogue/itemsearch.pl @@ -101,7 +101,7 @@ if (scalar keys %params > 0) { filters => [], }; - foreach my $p (qw(homebranch location itype ccode issues datelastborrowed notforloan)) { + foreach my $p (qw(homebranch holdingbranch location itype ccode issues datelastborrowed notforloan)) { if (my @q = $cgi->multi_param($p)) { if ($q[0] ne '') { my $f = { diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/catalogue/itemsearch.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/catalogue/itemsearch.tt index e52780e915..55f553eb1d 100644 --- a/koha-tmpl/intranet-tmpl/prog/en/modules/catalogue/itemsearch.tt +++ b/koha-tmpl/intranet-tmpl/prog/en/modules/catalogue/itemsearch.tt @@ -14,6 +14,7 @@ [% CASE 'isbn' %]ISBN [% CASE 'issn' %]ISSN [% CASE 'homebranch' %]Home library + [% CASE 'holdingbranch' %]Current location [% CASE 'All libraries' %]All libraries [% CASE 'location' %]Shelving location [% CASE 'All locations' %]All locations @@ -381,6 +382,11 @@ options = branches empty_option = "All libraries" %] + [% INCLUDE form_field_select + name="holdingbranch" + options = branches + empty_option = "All libraries" + %] [% INCLUDE form_field_select name="location" options = locations -- 2.39.5