Bugzilla – Attachment 160625 Details for
Bug 35721
Replace ModItemTransfer calls in circ/returns.pl
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 35721: ModItemTransfer -> Koha::Item->request_transfer - returns.pl
Bug-35721-ModItemTransfer---KohaItem-requesttransf.patch (text/plain), 1.66 KB, created by
Martin Renvoize (ashimema)
on 2024-01-08 12:56:51 UTC
(
hide
)
Description:
Bug 35721: ModItemTransfer -> Koha::Item->request_transfer - returns.pl
Filename:
MIME Type:
Creator:
Martin Renvoize (ashimema)
Created:
2024-01-08 12:56:51 UTC
Size:
1.66 KB
patch
obsolete
>From 4e5f099b64f5ad62538e9af66aa8bec140380424 Mon Sep 17 00:00:00 2001 >From: Martin Renvoize <martin.renvoize@ptfs-europe.com> >Date: Mon, 8 Jan 2024 12:55:01 +0000 >Subject: [PATCH] Bug 35721: ModItemTransfer -> Koha::Item->request_transfer - > returns.pl > >This patch replaces the call to ModItemTransfer in circ/returns.pl with >a call to Koha::Item->request_transfer and >Koha::Item::Transfer->transit. >--- > circ/returns.pl | 8 +++++--- > 1 file changed, 5 insertions(+), 3 deletions(-) > >diff --git a/circ/returns.pl b/circ/returns.pl >index 4ec8cc22596..cd8b7c82da6 100755 >--- a/circ/returns.pl >+++ b/circ/returns.pl >@@ -37,7 +37,6 @@ use DateTime; > use C4::Auth qw( get_template_and_user get_session haspermission ); > use C4::Circulation qw( barcodedecode GetBranchItemRule AddReturn updateWrongTransfer LostItem ); > use C4::Context; >-use C4::Items qw( ModItemTransfer ); > use C4::Members::Messaging; > use C4::Members; > use C4::Output qw( output_html_with_http_headers ); >@@ -242,9 +241,12 @@ if ($return_date_override) { > if ($dotransfer){ > # An item has been returned to a branch other than the homebranch, and the librarian has chosen to initiate a transfer > my $transferitem = $query->param('transferitem'); >- my $tobranch = $query->param('tobranch'); >+ my $item = Koha::Items->find( $transferitem ); >+ my $tobranchcode = $query->param('tobranch'); >+ my $tobranch = Koha::Libraries->find($tobranchcode); > my $trigger = $query->param('trigger'); >- ModItemTransfer($transferitem, $userenv_branch, $tobranch, $trigger); >+ my $transfer = $item->request_transfer({ to => $tobranch, reason => $trigger }); >+ $transfer->transit; > } > > if ($transit) { >-- >2.43.0
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 35721
:
160625
|
160631
|
160632
|
160649
|
160665
|
160691
|
168279
|
168280
|
172777
|
173043
|
173044
|
173356
|
173359
|
173360
|
173370
|
173853
|
173854
|
173855