X-Git-Url: http://git.freeside.biz/gitweb/?a=blobdiff_plain;f=httemplate%2Fview%2Fbill_batch.cgi;h=c848664ac9f23668a763bf22147e0854d237a880;hb=d9818900e0c2ec7da76200d05601cd534977151e;hp=3fca6ebbe5dd54a52bea07ca27d5bc30a96eaffc;hpb=0fb307c305e4bc2c9c27dc25a3308beae3a4d33c;p=freeside.git diff --git a/httemplate/view/bill_batch.cgi b/httemplate/view/bill_batch.cgi index 3fca6ebbe..c848664ac 100644 --- a/httemplate/view/bill_batch.cgi +++ b/httemplate/view/bill_batch.cgi @@ -1,28 +1,34 @@ -% if($magic eq 'print') { -<% include('/elements/header.html', "Download Batch") %> -
- -<% include('/elements/footer.html') %> -% } -% -% elsif($magic eq 'download') { -% $m->clear_buffer; -% $r->content_type('application/pdf'); -% $r->headers_out->add('Content-Disposition' => 'attachment;filename="invoice_batch_'.$batchnum.'.pdf"'); -<% $batch->pdf %> +% if($magic eq 'download') { +% my $content = $batch->pdf; % $batch->pdf(''); % my $error = $batch->replace; % warn "error deleting cached PDF: '$error'\n" if $error; +% +% $m->clear_buffer; +% $r->content_type('application/pdf'); +% $r->headers_out->add('Content-Disposition' => 'attachment;filename="invoice_batch_'.$batchnum.'.pdf"'); +<% $content %> +% } +% +% elsif ($magic eq 'download_popup') { +% +<& /elements/header-popup.html, + { 'etc' => 'BGCOLOR="#ccccff"' } &> + ++ +Download batch #<% $batchnum %> + + |