Browse Source

Bug 28520: Revert "Bug 12362: (QA follow-up) Fix ModItemTransfer cancellation handling"

This reverts commit fbba09f63f.

This commit was part of a series adding adding reverse transfers, i.e.
transfers that were created for transfers that were cancelled and
we wanted the item to return back to its sending library. This however
hid the information about transfer happening and we need another approach
to the problem.

Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>

Signed-off-by: Nick Clemens <nick@bywatersolutions.com>

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>

Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
21.05.x
Joonas Kylmälä 3 years ago
committed by Kyle M Hall
parent
commit
e98ce2c1fb
  1. 6
      Koha/Item.pm

6
Koha/Item.pm

@ -456,6 +456,9 @@ sub request_transfer {
Koha::Exceptions::Item::Transfer::InQueue->throw( transfer => $request )
if ( $request && !$params->{enqueue} && !$params->{replace} );
$request->cancel( { reason => $params->{reason}, force => 1 } )
if ( defined($request) && $params->{replace} );
my $transfer = Koha::Item::Transfer->new(
{
itemnumber => $self->itemnumber,
@ -467,9 +470,6 @@ sub request_transfer {
}
)->store();
$request->cancel( { reason => $params->{reason}, force => 1, replace => 1 } )
if ( defined($request) && $params->{replace} );
return $transfer;
}

Loading…
Cancel
Save