From 075e66b5e776637e2d465ea32a3717294818c805 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 Signed-off-by: Martin Renvoize --- 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 e18524307c..72074a8fdf 100755 --- a/catalogue/itemsearch.pl +++ b/catalogue/itemsearch.pl @@ -251,10 +251,11 @@ if ( defined $format ) { } $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 5d30c08a9b..39e95ac8fe 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 @@ -32,6 +32,6 @@ "[% (item.issues || 0) | html %]", "[% IF item.checkout %][% item.checkout.date_due | $KohaDates %][% END %]", "[% 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.30.2