Bugzilla – Attachment 174929 Details for
Bug 38505
CirculateILL checkout broken if existing biblio's item does not have a barcode
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 38505: CanBookBeIssued preparation: Appropriate behavior when barcode is falsy
Bug-38505-CanBookBeIssued-preparation-Appropriate-.patch (text/plain), 1.49 KB, created by
Pedro Amorim
on 2024-11-22 13:50:36 UTC
(
hide
)
Description:
Bug 38505: CanBookBeIssued preparation: Appropriate behavior when barcode is falsy
Filename:
MIME Type:
Creator:
Pedro Amorim
Created:
2024-11-22 13:50:36 UTC
Size:
1.49 KB
patch
obsolete
>From ec4c256ac09d278531702c6f375b1c9ee0fbb1c4 Mon Sep 17 00:00:00 2001 >From: Pedro Amorim <pedro.amorim@ptfs-europe.com> >Date: Thu, 21 Nov 2024 14:23:19 -0100 >Subject: [PATCH] Bug 38505: CanBookBeIssued preparation: Appropriate behavior > when barcode is falsy > >Before applying this patch, apply the CanBookBeIssued preparation: tests patch and run that, >Verify it fails, apply this patch. Run that same tests file again. > >----- About this change ----- > >CanBookBeIssued wants to find one item given a barcode. >If a falsy (undef, empty) barcode is supplied, UNKNOWN_BARCODE should be returned. > >Ensure this change does not introduce any regressions: >prove t/db_dependent/Circulation* >prove t/db_dependent/DecreaseLoanHighHolds.t >prove t/db_dependent/rollingloans.t >prove t/db_dependent/api/v1/checkouts.t >prove t/db_dependent/Patron/Borrower_PrevCheckout.t > >Signed-off-by: R <r.delahunty@arts.ac.uk> >--- > C4/Circulation.pm | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > >diff --git a/C4/Circulation.pm b/C4/Circulation.pm >index b9b66974be..80cead8a96 100644 >--- a/C4/Circulation.pm >+++ b/C4/Circulation.pm >@@ -780,7 +780,7 @@ sub CanBookBeIssued { > my $onsite_checkout = $params->{onsite_checkout} || 0; > my $override_high_holds = $params->{override_high_holds} || 0; > >- my $item_object = $params->{item} >+ my $item_object = !$barcode ? undef : $params->{item} > // Koha::Items->find( { barcode => $barcode } ); > > # MANDATORY CHECKS - unless item exists, nothing else matters >-- >2.39.5
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 38505
:
174892
|
174893
|
174894
|
174895
|
174896
|
174924
|
174928
| 174929 |
174930
|
174931
|
174932