Bugzilla – Attachment 159040 Details for
Bug 35216
Use return variable names from CanBookBeIssued in circulation.pl for consistency
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 35216: Rename error to issuingimpossible
Bug-35216-Rename-error-to-issuingimpossible.patch (text/plain), 2.50 KB, created by
Nick Clemens (kidclamp)
on 2023-11-16 12:04:13 UTC
(
hide
)
Description:
Bug 35216: Rename error to issuingimpossible
Filename:
MIME Type:
Creator:
Nick Clemens (kidclamp)
Created:
2023-11-16 12:04:13 UTC
Size:
2.50 KB
patch
obsolete
>From aef9be17f4da253ddbba8e9189cfe731019c6ce1 Mon Sep 17 00:00:00 2001 >From: Nick Clemens <nick@bywatersolutions.com> >Date: Wed, 1 Nov 2023 15:39:30 +0000 >Subject: [PATCH] Bug 35216: Rename error to issuingimpossible > >Test plan: >1 - Apply two patches >2 - Confirm code changes make sense >3 - Confirm you can check out items >4 - Confirm checkout blocks still block >--- > circ/circulation.pl | 14 +++++++------- > 1 file changed, 7 insertions(+), 7 deletions(-) > >diff --git a/circ/circulation.pl b/circ/circulation.pl >index 9052ccb6e5a..fe430eab09a 100755 >--- a/circ/circulation.pl >+++ b/circ/circulation.pl >@@ -317,9 +317,9 @@ if (@$barcodes) { > }; > > # always check for blockers on issuing >- my ( $error, $needsconfirmation, $alerts, $messages ); >+ my ( $issuingimpossible, $needsconfirmation, $alerts, $messages ); > try { >- ( $error, $needsconfirmation, $alerts, $messages ) = CanBookBeIssued( >+ ( $issuingimpossible, $needsconfirmation, $alerts, $messages ) = CanBookBeIssued( > $patron, > $barcode, $datedue, > $inprocess, >@@ -333,7 +333,7 @@ if (@$barcodes) { > die $_ unless blessed $_ && $_->can('rethrow'); > > if ( $_->isa('Koha::Exceptions::Calendar::NoOpenDays') ) { >- $error = { NO_OPEN_DAYS => 1 }; >+ $issuingimpossible = { NO_OPEN_DAYS => 1 }; > } else { > $_->rethrow; > } >@@ -353,7 +353,7 @@ if (@$barcodes) { > > # Fix for bug 7494: optional checkout-time fallback search for a book > >- if ( $error->{'UNKNOWN_BARCODE'} >+ if ( $issuingimpossible->{'UNKNOWN_BARCODE'} > && C4::Context->preference("itemBarcodeFallbackSearch") > && not $batch > ) >@@ -386,7 +386,7 @@ if (@$barcodes) { > my @blocking_error_codes = > ( $onsite_checkout and C4::Context->preference("OnSiteCheckoutsForce") ) > ? qw( UNKNOWN_BARCODE NO_OPEN_DAYS ) >- : ( keys %$error ); >+ : ( keys %$issuingimpossible ); > > if ( $error->{BOOKED_TO_ANOTHER} ) { > $template_params->{BOOKED_TO_ANOTHER} = $error->{BOOKED_TO_ANOTHER}; >@@ -395,8 +395,8 @@ if (@$barcodes) { > } > > foreach my $code ( @blocking_error_codes ) { >- if ($error->{$code}) { >- $template_params->{$code} = $error->{$code}; >+ if ($issuingimpossible->{$code}) { >+ $template_params->{$code} = $issuingimpossible->{$code}; > > $template_params->{IMPOSSIBLE} = 1; > $blocker = 1; >-- >2.30.2
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
|
Splinter Review
Attachments on
bug 35216
:
158185
|
158186
|
158187
|
159039
|
159040
|
159056
|
159057
|
159072
|
159073
|
159085
|
159086
|
159180
|
159181