|
Lines 74-80
if ( C4::Context->preference('AcqEnableFiles') ) {
Link Here
|
| 74 |
if ( $op && $op eq 'cud-close' ) { |
74 |
if ( $op && $op eq 'cud-close' ) { |
| 75 |
output_and_exit( $input, $cookie, $template, 'insufficient_permission' ) |
75 |
output_and_exit( $input, $cookie, $template, 'insufficient_permission' ) |
| 76 |
unless $logged_in_patron->has_permission( { acquisition => 'edit_invoices' } ); |
76 |
unless $logged_in_patron->has_permission( { acquisition => 'edit_invoices' } ); |
| 77 |
my @invoiceid = split( ',', $input->param('invoiceid') ); |
77 |
my @invoiceid = split( ',', scalar $input->param('invoiceid') ); |
| 78 |
foreach my $invoiceid ( @invoiceid ) { |
78 |
foreach my $invoiceid ( @invoiceid ) { |
| 79 |
CloseInvoice($invoiceid); |
79 |
CloseInvoice($invoiceid); |
| 80 |
} |
80 |
} |
|
Lines 87-93
if ( $op && $op eq 'cud-close' ) {
Link Here
|
| 87 |
elsif ( $op && $op eq 'cud-reopen' ) { |
87 |
elsif ( $op && $op eq 'cud-reopen' ) { |
| 88 |
output_and_exit( $input, $cookie, $template, 'insufficient_permission' ) |
88 |
output_and_exit( $input, $cookie, $template, 'insufficient_permission' ) |
| 89 |
unless $logged_in_patron->has_permission( { acquisition => 'reopen_closed_invoices' } ); |
89 |
unless $logged_in_patron->has_permission( { acquisition => 'reopen_closed_invoices' } ); |
| 90 |
my @invoiceid = split( ',', $input->param('invoiceid') ); |
90 |
my @invoiceid = split( ',', scalar $input->param('invoiceid') ); |
| 91 |
foreach my $invoiceid ( @invoiceid ) { |
91 |
foreach my $invoiceid ( @invoiceid ) { |
| 92 |
ReopenInvoice($invoiceid); |
92 |
ReopenInvoice($invoiceid); |
| 93 |
} |
93 |
} |