From d653550622af10414a14fa07537d418c971c7ef7 Mon Sep 17 00:00:00 2001 From: Kyle M Hall Date: Tue, 17 Nov 2020 07:22:02 -0500 Subject: [PATCH] Bug 20256: (QA follow-up) Implement for item search --- catalogue/itemsearch.pl | 7 ++++--- .../prog/en/includes/catalogue/itemsearch_item.json.inc | 2 +- .../prog/en/modules/catalogue/itemsearch_json.tt | 2 +- 3 files changed, 6 insertions(+), 5 deletions(-) diff --git a/catalogue/itemsearch.pl b/catalogue/itemsearch.pl index f5f66fe349..7d120e0f99 100755 --- a/catalogue/itemsearch.pl +++ b/catalogue/itemsearch.pl @@ -235,10 +235,11 @@ if (scalar keys %params > 0) { } $template->param( - filter => $filter, + filter => $filter, search_params => $search_params, - results => $results, - total_rows => $total_rows, + results => $results, + total_rows => $total_rows, + user => Koha::Patrons->find( $borrowernumber ), ); if ($format eq 'csv') { diff --git a/koha-tmpl/intranet-tmpl/prog/en/includes/catalogue/itemsearch_item.json.inc b/koha-tmpl/intranet-tmpl/prog/en/includes/catalogue/itemsearch_item.json.inc index 1933950c07..89d940869f 100644 --- a/koha-tmpl/intranet-tmpl/prog/en/includes/catalogue/itemsearch_item.json.inc +++ b/koha-tmpl/intranet-tmpl/prog/en/includes/catalogue/itemsearch_item.json.inc @@ -29,6 +29,6 @@ "[% AuthorisedValues.GetDescriptionByKohaField( kohafield => 'items.withdrawn', authorised_value => item.withdrawn ) || "" | html %]", "[% (item.issues || 0) | html %]", "[% FILTER escape_quotes ~%] -
+
[%~ END %]" ] diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/catalogue/itemsearch_json.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/catalogue/itemsearch_json.tt index 3c7b17d61b..3d46ae4708 100644 --- a/koha-tmpl/intranet-tmpl/prog/en/modules/catalogue/itemsearch_json.tt +++ b/koha-tmpl/intranet-tmpl/prog/en/modules/catalogue/itemsearch_json.tt @@ -4,7 +4,7 @@ "iTotalDisplayRecords": [% total_rows | html %], "aaData": [ [%- FOREACH item IN results -%] - [%- INCLUDE 'catalogue/itemsearch_item.json.inc' item = item -%] + [%- INCLUDE 'catalogue/itemsearch_item.json.inc' item = item, user = user -%] [%- UNLESS loop.last %],[% END -%] [%- END -%] ] -- 2.24.1 (Apple Git-126)