|
Lines 50-58
my ( $template, $loggedinuser, $cookie, $flags ) = get_template_and_user(
Link Here
|
| 50 |
} |
50 |
} |
| 51 |
); |
51 |
); |
| 52 |
|
52 |
|
| 53 |
my $op = $input->param('op') // q{}; |
53 |
my $op = $input->param('op') // q{}; |
| 54 |
my $borrowernumber = $input->param('borrowernumber'); |
54 |
my $borrowernumber = $input->param('borrowernumber'); |
| 55 |
my $discharge_id = $input->param('discharge_id'); |
55 |
my $discharge_id = $input->param('discharge_id'); |
|
|
56 |
my $cancellation_reason = $input->param('cancellation-reason'); |
| 56 |
|
57 |
|
| 57 |
unless ( C4::Context->preference('useDischarge') ) { |
58 |
unless ( C4::Context->preference('useDischarge') ) { |
| 58 |
print $input->redirect("/cgi-bin/koha/circ/circulation.pl?borrowernumber=$borrowernumber&nopermission=1"); |
59 |
print $input->redirect("/cgi-bin/koha/circ/circulation.pl?borrowernumber=$borrowernumber&nopermission=1"); |
|
Lines 73-80
if ( $op eq "cud-cancel-discharge" ) {
Link Here
|
| 73 |
unless ( Koha::Patron::Discharge::is_cancelled( { discharge_id => $discharge_id } ) ) { |
74 |
unless ( Koha::Patron::Discharge::is_cancelled( { discharge_id => $discharge_id } ) ) { |
| 74 |
Koha::Patron::Discharge::cancel( |
75 |
Koha::Patron::Discharge::cancel( |
| 75 |
{ |
76 |
{ |
| 76 |
discharge_id => $discharge_id, |
77 |
discharge_id => $discharge_id, |
| 77 |
borrowernumber => $borrowernumber, |
78 |
borrowernumber => $borrowernumber, |
|
|
79 |
cancellation_reason => $cancellation_reason, |
| 78 |
} |
80 |
} |
| 79 |
); |
81 |
); |
| 80 |
} |
82 |
} |
| 81 |
- |
|
|