From a3c7eaeb221da06f96c1bd3c288e62c83b4d7be2 Mon Sep 17 00:00:00 2001 From: einhverfr Date: Thu, 7 Dec 2006 18:26:43 +0000 Subject: Fixes some issues with saving parts. Also is a step towards fixing printing with 3-arg open statements. Printing is not verified yet. git-svn-id: https://ledger-smb.svn.sourceforge.net/svnroot/ledger-smb/branches/1.2@739 4979c152-3d1c-0410-bac9-87ea11338e46 --- bin/io.pl | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) (limited to 'bin/io.pl') diff --git a/bin/io.pl b/bin/io.pl index ec824540..31e8636c 100755 --- a/bin/io.pl +++ b/bin/io.pl @@ -1427,8 +1427,8 @@ sub print_form { $form->{pre} = "\n
" if $form->{format} eq 'txt';
 
   if ($form->{media} !~ /(screen|queue|email)/) {
-    $form->{OUT} = "| ${LedgerSMB::SysConfig::printer}{$form->{media}}";
-    
+    $form->{OUT} = "${LedgerSMB::SysConfig::printer}{$form->{media}}";
+    $form->{printmode} = '|-';
     $form->{OUT} =~ s/<%(fax)%>/<%$form->{vc}$1%>/;
     $form->{OUT} =~ s/<%(.*?)%>/$form->{$1}/g;
 
@@ -1458,6 +1458,7 @@ sub print_form {
 
     $form->{plainpaper} = 1;
     $form->{OUT} = "${LedgerSMB::Sysconfig::sendmail}";
+    $form->{printmode} = '|-';
 
     if ($form->{emailed} !~ /$form->{formname}/) {
       $form->{emailed} .= " $form->{formname}";
@@ -1513,7 +1514,9 @@ sub print_form {
     }
 
     $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/^ //;
-- 
cgit v1.2.3