diff options
Diffstat (limited to 'bin/arapprn.pl')
-rwxr-xr-x | bin/arapprn.pl | 21 |
1 files changed, 12 insertions, 9 deletions
diff --git a/bin/arapprn.pl b/bin/arapprn.pl index 18fd884f..9b2f025a 100755 --- a/bin/arapprn.pl +++ b/bin/arapprn.pl @@ -115,9 +115,10 @@ sub print { } $filename .= ($form->{format} eq 'postscript') ? '.ps' : '.pdf'; - $form->{OUT} = ">${LedgerSMB::Sysconfig::spool}/$filename" if - $form->{media} ne 'screen'; - + if ($form->{media} ne 'screen'){ + $form->{OUT} = "${LedgerSMB::Sysconfig::spool}/$filename"; + $form->{printmode} = '>'; + } $form->{queued} .= " $form->{formname} $filename"; $form->{queued} =~ s/^ //; $printform = new Form; @@ -216,8 +217,8 @@ sub print_check { id => $form->{id} ); $form->{audittrail} .= $form->audittrail("", \%myconfig, \%audittrail); - $form->{OUT} = ">${LedgerSMB::Sysconfig::spool}/$filename"; - + $form->{OUT} = "${LedgerSMB::Sysconfig::spool}/$filename"; + $form->{printmode} = '>'; $form->{queued} .= " $form->{formname} $filename"; $form->{queued} =~ s/^ //; } @@ -227,8 +228,8 @@ sub print_check { %queued = split / /, $form->{queued}; - $form->{OUT} = "| ${LedgerSMB::Sysconfig::printer}{$form->{media}}"; - + $form->{OUT} = "${LedgerSMB::Sysconfig::printer}{$form->{media}}"; + $form->{printmode} = '|-'; if ($form->{printed} !~ /$form->{formname}/) { $form->{printed} .= " $form->{formname}"; @@ -424,7 +425,8 @@ sub print_transaction { } $filename .= ($form->{format} eq 'postscript') ? '.ps' : '.pdf'; - $form->{OUT} = ">${LedgerSMB::Sysconfig::spool}/$filename"; + $form->{OUT} = "${LedgerSMB::Sysconfig::spool}/$filename"; + $form->{printmode} = '>'; $form->{queued} .= " $form->{formname} $filename"; $form->{queued} =~ s/^ //; @@ -444,7 +446,8 @@ sub print_transaction { } if ($form->{media} !~ /(queue|screen)/) { - $form->{OUT} = "| ${LedgerSMB::Sysconfig::printer}{$form->{media}}"; + $form->{OUT} = "${LedgerSMB::Sysconfig::printer}{$form->{media}}"; + $form->{printmode} = '|-'; if ($form->{printed} !~ /$form->{formname}/) { |