View | Details | Raw Unified | Return to bug 26108
Collapse All | Expand All

(-)a/C4/Circulation.pm (-3 / +2 lines)
Lines 2124-2130 sub AddReturn { Link Here
2124
    my $lookahead= C4::Context->preference('ConfirmFutureHolds'); #number of days to look for future holds
2124
    my $lookahead= C4::Context->preference('ConfirmFutureHolds'); #number of days to look for future holds
2125
    ($resfound, $resrec, undef) = C4::Reserves::CheckReserves( $item->itemnumber, undef, $lookahead ) unless ( $item->withdrawn );
2125
    ($resfound, $resrec, undef) = C4::Reserves::CheckReserves( $item->itemnumber, undef, $lookahead ) unless ( $item->withdrawn );
2126
    # if a hold is found and is waiting at another branch, change the priority back to 1 and trigger the hold (this will trigger a transfer and update the hold status properly)
2126
    # if a hold is found and is waiting at another branch, change the priority back to 1 and trigger the hold (this will trigger a transfer and update the hold status properly)
2127
    if ( $resfound eq "Waiting" and $branch ne $resrec->{branchcode} ) {
2127
    if ( $resfound and $resfound eq "Waiting" and $branch ne $resrec->{branchcode} ) {
2128
        my $hold = C4::Reserves::RevertWaitingStatus( { itemnumber => $item->itemnumber } );
2128
        my $hold = C4::Reserves::RevertWaitingStatus( { itemnumber => $item->itemnumber } );
2129
        $resfound = 'Reserved';
2129
        $resfound = 'Reserved';
2130
        $resrec = $hold->unblessed;
2130
        $resrec = $hold->unblessed;
Lines 2206-2212 sub AddReturn { Link Here
2206
        }
2206
        }
2207
    }
2207
    }
2208
2208
2209
    if ( $issue ) {
2209
    if ( $doreturn and $issue ) {
2210
        my $checkin = Koha::Old::Checkouts->find($issue->id);
2210
        my $checkin = Koha::Old::Checkouts->find($issue->id);
2211
2211
2212
        Koha::Plugins->call('after_circ_action', {
2212
        Koha::Plugins->call('after_circ_action', {
2213
- 

Return to bug 26108