From 12ef157d757431520d63ab154b9572a855acf317 Mon Sep 17 00:00:00 2001 From: Fridolin Somers Date: Wed, 19 Jun 2019 13:42:16 +0200 Subject: [PATCH] Bug 23158: keep on-site checkout info when using itemBarcodeFallbackSearch When using preference itemBarcodeFallbackSearch one can enter a search term instead of a barcode in checkout form. If on-site is selected this should be transmitted to itemBarcodeFallbackSearch form. Test plan : 1) Enable system preferences "itemBarcodeFallbackSearch" and "OnSiteCheckouts" 2) Disable system preference "ConsiderOnSiteCheckoutsAsNormalCheckouts" 3) Go to a patron circulation page 4) Check "On-site checkout" in "Checkout settings" 5) Enter a barcode in checkout form and click on "Check out" 6) You see the checkout in table with red "(On-site checkout)" 7) Check "On-site checkout" in "Checkout settings" 8) Enter the title of a record in in checkout form and click on "Check out" 9) Click on "Checkout" on a line 10) You see the checkout in table with red "(On-site checkout)" Signed-off-by: Arthur Bousquet Signed-off-by: Jonathan Druart Signed-off-by: Martin Renvoize --- circ/circulation.pl | 4 +++- koha-tmpl/intranet-tmpl/prog/en/modules/circ/circulation.tt | 1 + 2 files changed, 4 insertions(+), 1 deletion(-) diff --git a/circ/circulation.pl b/circ/circulation.pl index 72a38465ad..8fcb9bbdee 100755 --- a/circ/circulation.pl +++ b/circ/circulation.pl @@ -329,7 +329,10 @@ if ($patron) { if (@$barcodes) { my $checkout_infos; for my $barcode ( @$barcodes ) { + my $template_params = { barcode => $barcode }; + $template_params->{onsite_checkout} = $onsite_checkout; + # always check for blockers on issuing my ( $error, $question, $alerts, $messages ) = CanBookBeIssued( $patron, @@ -412,7 +415,6 @@ if (@$barcodes) { $template_params->{getTitleMessageIteminfo} = $biblio->title; $template_params->{getBarcodeMessageIteminfo} = $item->barcode; $template_params->{NEEDSCONFIRMATION} = 1; - $template_params->{onsite_checkout} = $onsite_checkout; $template_params->{auto_renew} = $session->param('auto_renew'); $confirm_required = 1; } diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/circ/circulation.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/circ/circulation.tt index 5ddcb78acf..41dec3b814 100644 --- a/koha-tmpl/intranet-tmpl/prog/en/modules/circ/circulation.tt +++ b/koha-tmpl/intranet-tmpl/prog/en/modules/circ/circulation.tt @@ -459,6 +459,7 @@ + -- 2.39.5