diff options
Diffstat (limited to 'FS')
-rw-r--r-- | FS/FS/bill_batch.pm | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/FS/FS/bill_batch.pm b/FS/FS/bill_batch.pm index ec5c19456..1a46db0b2 100644 --- a/FS/FS/bill_batch.pm +++ b/FS/FS/bill_batch.pm @@ -84,6 +84,7 @@ sub print_pdf { die $error if $error; } } + $job->update_statustext(100, 'Combining invoices') if $job; return $pdf_out->toPDF; } @@ -144,6 +145,11 @@ sub process_print_pdf { my $batch = FS::bill_batch->by_key($param->{batchnum}); die "batch '$param->{batchnum}' not found!\n" if !$batch; + if ( $param->{'close'} ) { + my $error = $batch->close; + die $error if $error; + } + my $pdf = $batch->print_pdf($job); $batch->pdf($pdf); my $error = $batch->replace; |