diff options
-rw-r--r-- | FS/FS/Misc.pm | 6 | ||||
-rw-r--r-- | httemplate/pref/pref-process.html | 2 | ||||
-rw-r--r-- | httemplate/pref/pref.html | 4 |
3 files changed, 9 insertions, 3 deletions
diff --git a/FS/FS/Misc.pm b/FS/FS/Misc.pm index 5e89abc0c..de9fb522f 100644 --- a/FS/FS/Misc.pm +++ b/FS/FS/Misc.pm @@ -699,7 +699,8 @@ sub generate_ps { open(POSTSCRIPT, "<$file.ps") or die "can't open $file.ps: $! (error in LaTeX template?)\n"; - unlink("$file.dvi", "$file.log", "$file.aux", "$file.ps", "$file.tex"); + unlink("$file.dvi", "$file.log", "$file.aux", "$file.ps", "$file.tex") + unless $FS::CurrentUser::CurrentUser->option('save_tmp_typesetting'); my $ps = ''; @@ -757,7 +758,8 @@ sub generate_pdf { open(PDF, "<$file.pdf") or die "can't open $file.pdf: $! (error in LaTeX template?)\n"; - unlink("$file.dvi", "$file.log", "$file.aux", "$file.pdf", "$file.tex"); + unlink("$file.dvi", "$file.log", "$file.aux", "$file.pdf", "$file.tex") + unless $FS::CurrentUser::CurrentUser->option('save_tmp_typesetting'); my $pdf = ''; while (<PDF>) { diff --git a/httemplate/pref/pref-process.html b/httemplate/pref/pref-process.html index c4fef0311..84f0832bf 100644 --- a/httemplate/pref/pref-process.html +++ b/httemplate/pref/pref-process.html @@ -57,7 +57,7 @@ unless ( $error ) { # if ($access_user) { vonage-fromnumber vonage-username vonage-password cust_pkg-display_times show_pkgnum show_confitem_counts export_getsettings - show_db_profile save_db_profile + show_db_profile save_db_profile save_tmp_typesetting height width availHeight availWidth colorDepth ); diff --git a/httemplate/pref/pref.html b/httemplate/pref/pref.html index 1e9671dcc..9537fed34 100644 --- a/httemplate/pref/pref.html +++ b/httemplate/pref/pref.html @@ -157,6 +157,10 @@ Development <TH>Save database profiling logs (when available): </TH> <TD><INPUT TYPE="checkbox" NAME="save_db_profile" VALUE="1" <% $curuser->option('save_db_profile') ? 'CHECKED' : '' %>></TD> </TR> + <TR> + <TH>Save temporary invoice typesetting files: </TH> + <TD><INPUT TYPE="checkbox" NAME="save_tmp_typesetting" VALUE="1" <% $curuser->option('save_tmp_typesetting') ? 'CHECKED' : '' %>></TD> + </TR> </TABLE> <BR> |