Lines 113-119
if ( $op eq 'cud-move' ) {
Link Here
|
113 |
elsif ( $op eq 'cud-cancel' ) { |
113 |
elsif ( $op eq 'cud-cancel' ) { |
114 |
my $reserve_id = $input->param('reserve_id'); |
114 |
my $reserve_id = $input->param('reserve_id'); |
115 |
my $cancellation_reason = $input->param("cancellation-reason"); |
115 |
my $cancellation_reason = $input->param("cancellation-reason"); |
|
|
116 |
my $transfer = $input->param("transfer-cancel") ? "1" : "0"; |
116 |
my $hold = Koha::Holds->find($reserve_id); |
117 |
my $hold = Koha::Holds->find($reserve_id); |
|
|
118 |
|
119 |
if( $transfer ) { |
120 |
warn($hold->item()->get_transfer); |
121 |
$hold->item()->get_transfer->cancel( { reason => 'Manual', 'force' => '1' } ); |
122 |
} |
117 |
$hold->cancel( { cancellation_reason => $cancellation_reason } ) if $hold; |
123 |
$hold->cancel( { cancellation_reason => $cancellation_reason } ) if $hold; |
118 |
} |
124 |
} |
119 |
elsif ( $op eq 'cud-setLowestPriority' ) { |
125 |
elsif ( $op eq 'cud-setLowestPriority' ) { |
Lines 632-637
if ( ( $findborrower && $borrowernumber_hold || $findclub && $club_hold )
Link Here
|
632 |
$reserve{'found'} = $res->is_found(); |
638 |
$reserve{'found'} = $res->is_found(); |
633 |
$reserve{'inprocessing'} = $res->is_in_processing(); |
639 |
$reserve{'inprocessing'} = $res->is_in_processing(); |
634 |
$reserve{'intransit'} = $res->is_in_transit(); |
640 |
$reserve{'intransit'} = $res->is_in_transit(); |
|
|
641 |
$reserve{'transfer'} = $res->item()->get_transfer() ? '1' : '0'; |
635 |
} |
642 |
} |
636 |
elsif ( $res->priority() > 0 ) { |
643 |
elsif ( $res->priority() > 0 ) { |
637 |
if ( my $item = $res->item() ) { |
644 |
if ( my $item = $res->item() ) { |
638 |
- |
|
|