Bugzilla – Attachment 152372 Details for
Bug 34016
Enable fulfillment of recalled items through SIP2
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 34016: [WIP] Working on fulfilling recalls via SIP
Bug-34016-WIP-Working-on-fulfilling-recalls-via-SI.patch (text/plain), 2.71 KB, created by
Aleisha Amohia
on 2023-06-15 05:22:07 UTC
(
hide
)
Description:
Bug 34016: [WIP] Working on fulfilling recalls via SIP
Filename:
MIME Type:
Creator:
Aleisha Amohia
Created:
2023-06-15 05:22:07 UTC
Size:
2.71 KB
patch
obsolete
>From 8888713161cf2ad0ce8a0c95b6562a91fcad4803 Mon Sep 17 00:00:00 2001 >From: Aleisha Amohia <aleishaamohia@hotmail.com> >Date: Thu, 15 Jun 2023 17:21:37 +1200 >Subject: [PATCH] Bug 34016: [WIP] Working on fulfilling recalls via SIP > >--- > C4/SIP/ILS/Transaction/Checkout.pm | 18 ++++++++++++++---- > 1 file changed, 14 insertions(+), 4 deletions(-) > >diff --git a/C4/SIP/ILS/Transaction/Checkout.pm b/C4/SIP/ILS/Transaction/Checkout.pm >index d9056f1c824..d8bd50481e1 100644 >--- a/C4/SIP/ILS/Transaction/Checkout.pm >+++ b/C4/SIP/ILS/Transaction/Checkout.pm >@@ -48,7 +48,7 @@ sub do_checkout { > my $patron = Koha::Patrons->find($self->{patron}->{borrowernumber}); > my $overridden_duedate; # usually passed as undef to AddIssue > my $prevcheckout_block_checkout = $account->{prevcheckout_block_checkout}; >- my ($issuingimpossible, $needsconfirmation) = _can_we_issue($patron, $barcode, 0); >+ my ($issuingimpossible, $needsconfirmation, $messages) = _can_we_issue($patron, $barcode, 0); > > if ( $no_block_due_date ) { > my $year = substr($no_block_due_date,0,4); >@@ -108,6 +108,10 @@ sub do_checkout { > $self->screen_msg('Item must be checked out at a circulation desk'); > $noerror = 0; > last; >+ } elsif ( $confirmation eq 'RECALLED' ) { >+ $self->screen_msg('Item has been recalled for another patron'); >+ $noerror = 0; >+ last; > } else { > # We've been returned a case other than those above > $self->screen_msg("Item cannot be issued: $confirmation"); >@@ -141,7 +145,13 @@ sub do_checkout { > }); > } else { > # can issue >- my $issue = AddIssue( $patron->unblessed, $barcode, $overridden_duedate, 0 ); >+ my $recall_id; >+ foreach (keys %{$messages}) { >+ if ( $_ eq "RECALLED" ) { >+ $recall_id = $messages->{RECALLED}; >+ } >+ } >+ my $issue = AddIssue( $patron->unblessed, $barcode, $overridden_duedate, 0, undef, undef, { recall_id => $recall_id } ); > $self->{due} = $self->duedatefromissue($issue, $itemnumber); > } > >@@ -152,7 +162,7 @@ sub do_checkout { > sub _can_we_issue { > my ( $patron, $barcode, $pref ) = @_; > >- my ( $issuingimpossible, $needsconfirmation, $alerts ) = >+ my ( $issuingimpossible, $needsconfirmation, $alerts, $messages ) = > CanBookBeIssued( $patron, $barcode, undef, 0, $pref ); > for my $href ( $issuingimpossible, $needsconfirmation ) { > >@@ -163,7 +173,7 @@ sub _can_we_issue { > } > } > } >- return ( $issuingimpossible, $needsconfirmation ); >+ return ( $issuingimpossible, $needsconfirmation, $messages ); > } > > 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 34016
:
152371
|
152372
|
152396
|
152397
|
152458
|
152461
|
152462
|
155382
|
155383
|
155471
|
156154
|
156155