[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
SF.net SVN: ledger-smb: [281] trunk/bin
- Subject: SF.net SVN: ledger-smb: [281] trunk/bin
- From: ..hidden..
- Date: Mon, 23 Oct 2006 19:38:55 -0700
Revision: 281
http://svn.sourceforge.net/ledger-smb/?rev=281&view=rev
Author: einhverfr
Date: 2006-10-23 19:38:49 -0700 (Mon, 23 Oct 2006)
Log Message:
-----------
Moved %printer from ledger-smb.conf to Ledger::Sysconfig
Modified Paths:
--------------
trunk/bin/admin.pl
trunk/bin/am.pl
trunk/bin/arap.pl
trunk/bin/arapprn.pl
trunk/bin/bp.pl
trunk/bin/cp.pl
trunk/bin/io.pl
trunk/bin/jc.pl
trunk/bin/pos.pl
trunk/bin/rc.pl
trunk/bin/rp.pl
Modified: trunk/bin/admin.pl
===================================================================
--- trunk/bin/admin.pl 2006-10-24 01:47:58 UTC (rev 280)
+++ trunk/bin/admin.pl 2006-10-24 02:38:49 UTC (rev 281)
@@ -464,11 +464,11 @@
$selectstylesheet .= "<option></option>\n";
- if (%printer && ${LedgerSMB::Sysconfig::latex}) {
+ if (%{LedgerSMB::Sysconfig::printer} && ${LedgerSMB::Sysconfig::latex}) {
$selectprinter = "<option></option>\n";
- foreach $item (sort keys %printer) {
+ foreach $item (sort keys %{LedgerSMB::Sysconfig::printer}) {
if ($myconfig->{printer} eq $item) {
$selectprinter .= qq|<option value="$item" selected>$item</option>\n|;
Modified: trunk/bin/am.pl
===================================================================
--- trunk/bin/am.pl 2006-10-24 01:47:58 UTC (rev 280)
+++ trunk/bin/am.pl 2006-10-24 02:38:49 UTC (rev 281)
@@ -2064,9 +2064,9 @@
}
$selectstylesheet .= "<option>\n";
- if (%printer && ${LedgerSMB::Sysconfig::latex}) {
+ if (%{LedgerSMB::Sysconfig::printer} && ${LedgerSMB::Sysconfig::latex}) {
$selectprinter = "<option>\n";
- foreach $item (sort keys %printer) {
+ foreach $item (sort keys %{LedgerSMB::Sysconfig::printer}) {
if ($myconfig{printer} eq $item) {
$selectprinter .= qq|<option value="$item" selected>$item\n|;
} else {
@@ -2972,7 +2972,7 @@
for (keys %$form) { $pt->{$_} = $form->{$_} }
my $defaultprinter;
- while (my ($key, $value) = each %printer) {
+ while (my ($key, $value) = each %{LedgerSMB::Sysconfig::printer}) {
if ($value =~ /lpr/) {
$defaultprinter = $key;
last;
@@ -3197,7 +3197,8 @@
@f = split /:/, $pt->{recurringprint};
for ($j = 0; $j <= $#f; $j += 3) {
$media = $f[$j+2];
- $media ||= $myconfig->{printer} if $printer{$myconfig->{printer}};
+ $media ||= $myconfig->{printer}
+ if ${LedgerSMB::Sysconfig::printer}{$myconfig->{printer}};
$media ||= $defaultprinter;
$form->info("\n".$locale->text('Printing')." ".$locale->text($f{$f[$j]})." $form->{reference}");
Modified: trunk/bin/arap.pl
===================================================================
--- trunk/bin/arap.pl 2006-10-24 01:47:58 UTC (rev 280)
+++ trunk/bin/arap.pl 2006-10-24 02:38:49 UTC (rev 281)
@@ -615,9 +615,9 @@
}
- if (%printer && ${LedgerSMB::Sysconfig::latex} && %formname) {
+ if (%{LedgerSMB::Sysconfig::printer} && ${LedgerSMB::Sysconfig::latex} && %formname) {
$selectprinter = qq|<option>\n|;
- for (sort keys %printer) { $selectprinter .= qq|<option value="$_">$_\n| }
+ for (sort keys %{LedgerSMB::Sysconfig::printer}) { $selectprinter .= qq|<option value="$_">$_\n| }
# formname:format:printer
@p = split /:/, $form->{recurringprint};
Modified: trunk/bin/arapprn.pl
===================================================================
--- trunk/bin/arapprn.pl 2006-10-24 01:47:58 UTC (rev 280)
+++ trunk/bin/arapprn.pl 2006-10-24 02:38:49 UTC (rev 281)
@@ -226,7 +226,7 @@
%queued = split / /, $form->{queued};
- $form->{OUT} = "| $printer{$form->{media}}";
+ $form->{OUT} = "| ${LedgerSMB::Sysconfig::printer}{$form->{media}}";
if ($form->{printed} !~ /$form->{formname}/) {
@@ -443,7 +443,7 @@
}
if ($form->{media} !~ /(queue|screen)/) {
- $form->{OUT} = "| $printer{$form->{media}}";
+ $form->{OUT} = "| ${LedgerSMB::Sysconfig::printer}{$form->{media}}";
if ($form->{printed} !~ /$form->{formname}/) {
@@ -625,8 +625,8 @@
$form->{selectformat} = qq|<option value="html">html\n|;
- if (%printer && ${LedgerSMB::Sysconfig::latex}) {
- for (sort keys %printer) { $media .= qq|
+ if (%{LedgerSMB::Sysconfig::printer} && ${LedgerSMB::Sysconfig::latex}) {
+ for (sort keys %{LedgerSMB::Sysconfig::printer}) { $media .= qq|
<option value="$_">$_| }
}
Modified: trunk/bin/bp.pl
===================================================================
--- trunk/bin/bp.pl 2006-10-24 01:47:58 UTC (rev 280)
+++ trunk/bin/bp.pl 2006-10-24 02:38:49 UTC (rev 281)
@@ -271,7 +271,7 @@
for $i (1 .. $form->{rowcount}) {
if ($form->{"checked_$i"}) {
- $form->{OUT} = "| $printer{$form->{media}}";
+ $form->{OUT} = "| ${LedgerSMB::Sysconfig::printer}{$form->{media}}";
$form->info($locale->text('Printing')." ...");
if (BP->print_spool(\%myconfig, \%$form, ${LedgerSMB::Sysconfig::spool})) {
@@ -496,8 +496,8 @@
$form->hide_form(qw(callback title vc type sort module account path login sessionid));
- if (%printer && ${LedgerSMB::Sysconfig::latex}) {
- foreach $key (sort keys %printer) {
+ if (%{LedgerSMB::Sysconfig::printer} && ${LedgerSMB::Sysconfig::latex}) {
+ foreach $key (sort keys %{LedgerSMB::Sysconfig::printer}) {
print qq|
<input name=media type=radio class=radio value="$key" |;
print qq|checked| if $key eq $myconfig{printer};
Modified: trunk/bin/cp.pl
===================================================================
--- trunk/bin/cp.pl 2006-10-24 01:47:58 UTC (rev 280)
+++ trunk/bin/cp.pl 2006-10-24 02:38:49 UTC (rev 281)
@@ -457,8 +457,8 @@
$media = qq|<select name=media>
<option value=screen>|.$locale->text('Screen');
- if (%printer) {
- for (sort keys %printer) { $media .= qq|
+ if (%{LedgerSMB::Sysconfig::printer}) {
+ for (sort keys %{LedgerSMB::Sysconfig::printer}) { $media .= qq|
<option value="$_">$_| }
}
@@ -1064,8 +1064,8 @@
$media = qq|<select name=media>
<option value=screen>|.$locale->text('Screen');
- if (%printer) {
- for (sort keys %printer) { $media .= qq|
+ if (%{LedgerSMB::Sysconfig::printer}) {
+ for (sort keys %{LedgerSMB::Sysconfig::printer}) { $media .= qq|
<option value="$_">$_| }
}
@@ -1266,7 +1266,7 @@
$form->{IN} = "$form->{formname}.tex";
if ($form->{media} ne 'screen') {
- $form->{OUT} = "| $printer{$form->{media}}";
+ $form->{OUT} = "| ${LedgerSMB::Sysconfig::printer}{$form->{media}}";
}
$form->parse_template(\%myconfig, ${LedgerSMB::Sysconfig::userspath});
Modified: trunk/bin/io.pl
===================================================================
--- trunk/bin/io.pl 2006-10-24 01:47:58 UTC (rev 280)
+++ trunk/bin/io.pl 2006-10-24 02:38:49 UTC (rev 281)
@@ -1099,8 +1099,8 @@
$media = qq|<select name=media>
<option value="screen">|.$locale->text('Screen');
- if (%printer && ${LedgerSMB::Sysconfig::latex}) {
- for (sort keys %printer) { $media .= qq|
+ if (%{LedgerSMB::Sysconfig::printer} && ${LedgerSMB::Sysconfig::latex}) {
+ for (sort keys %{LedgerSMB::Sysconfig::printer}) { $media .= qq|
<option value="$_">$_| }
}
if (${LedgerSMB::Sysconfig::latex}) {
@@ -1138,7 +1138,7 @@
<td>$media</td>
|;
- if (%printer && ${LedgerSMB::Sysconfig::latex} && $form->{media} ne 'email') {
+ if (%{LedgerSMB::Sysconfig::printer} && ${LedgerSMB::Sysconfig::latex} && $form->{media} ne 'email') {
print qq|
<td nowrap>|.$locale->text('Copies').qq|
<input name=copies size=2 value=$form->{copies}></td>
@@ -1427,7 +1427,7 @@
$form->{pre} = "<body bgcolor=#ffffff>\n<pre>" if $form->{format} eq 'txt';
if ($form->{media} !~ /(screen|queue|email)/) {
- $form->{OUT} = "| $printer{$form->{media}}";
+ $form->{OUT} = "| ${LedgerSMB::SysConfig::printer}{$form->{media}}";
$form->{OUT} =~ s/<%(fax)%>/<%$form->{vc}$1%>/;
$form->{OUT} =~ s/<%(.*?)%>/$form->{$1}/g;
Modified: trunk/bin/jc.pl
===================================================================
--- trunk/bin/jc.pl 2006-10-24 01:47:58 UTC (rev 280)
+++ trunk/bin/jc.pl 2006-10-24 02:38:49 UTC (rev 281)
@@ -1761,8 +1761,8 @@
$form->{selectformat} = qq|<option value="html">html\n|;
- if (%printer && ${LedgerSMB::Sysconfig::latex}) {
- for (sort keys %printer) { $media .= qq|
+ if (%{LedgerSMB::Sysconfig::printer} && ${LedgerSMB::Sysconfig::latex}) {
+ for (sort keys %{LedgerSMB::Sysconfig::printer}) { $media .= qq|
<option value="$_">$_| }
}
@@ -1859,7 +1859,7 @@
}
if ($form->{media} !~ /(screen|queue)/) {
- $form->{OUT} = "| $printer{$form->{media}}";
+ $form->{OUT} = "| ${LedgerSMB::Sysconfig::printer}{$form->{media}}";
if ($form->{printed} !~ /$form->{formname}/) {
$form->{printed} .= " $form->{formname}";
Modified: trunk/bin/pos.pl
===================================================================
--- trunk/bin/pos.pl 2006-10-24 01:47:58 UTC (rev 280)
+++ trunk/bin/pos.pl 2006-10-24 02:38:49 UTC (rev 281)
@@ -77,7 +77,7 @@
}
sub open_drawer{
- open (PRINTER, "|-", $printer{Printer});
+ open (PRINTER, "|-", ${LedgerSMB::Sysconfig::printer}{Printer});
print PRINTER $pos_config{'rp_cash_open'};
close PRINTER;
sleep 1;
@@ -840,7 +840,7 @@
}
if ($form->{media} ne 'screen') {
- $form->{OUT} = "| $printer{$form->{media}}";
+ $form->{OUT} = "| ${LedgerSMB::Sysconfig::printer}{$form->{media}}";
}
$form->{discount} = $form->format_amount(\%myconfig, $form->{discount} * 100);
@@ -931,8 +931,8 @@
<td><input class=radio type=radio name=media value="screen"></td>
<td>|.$locale->text('Screen').qq|</td>|;
- if (%printer) {
- for (keys %printer) {
+ if (%{LedgerSMB::Sysconfig::printer}) {
+ for (keys %{LedgerSMB::Sysconfig::printer}) {
$media .= qq|
<td><input class=radio type=radio name=media value="$_"></td>
<td nowrap>$_</td>
Modified: trunk/bin/rc.pl
===================================================================
--- trunk/bin/rc.pl 2006-10-24 01:47:58 UTC (rev 280)
+++ trunk/bin/rc.pl 2006-10-24 02:38:49 UTC (rev 281)
@@ -402,7 +402,7 @@
$cash = join ("\n", @cashlines);
$foot = $locale->text("Cumulative Error: ")."$difference\n";
$foot .= $locale->text('Reset Till By ')."$amount\n\n\n\n\n\n\n\n\n\n";
- open (PRN, "|-", $printer{Printer});
+ open (PRN, "|-", ${LedgerSMB::Sysconfig::printer}{Printer});
print PRN $head;
print PRN $lines;
print PRN $cash;
Modified: trunk/bin/rp.pl
===================================================================
--- trunk/bin/rp.pl 2006-10-24 01:47:58 UTC (rev 280)
+++ trunk/bin/rp.pl 2006-10-24 02:38:49 UTC (rev 281)
@@ -1751,8 +1751,8 @@
$media = qq|
<td><select name=media>
<option value=screen>|.$locale->text('Screen');
- if (%printer && ${LedgerSMB::Sysconfig::latex}) {
- for (sort keys %printer) { $media .= qq|
+ if (%{LedgerSMB::Sysconfig::printer} && ${LedgerSMB::Sysconfig::latex}) {
+ for (sort keys %{LedgerSMB::Sysconfig::printer}) { $media .= qq|
<option value="$_">$_| }
}
}
@@ -1774,7 +1774,7 @@
$media
|;
- if (%printer && ${LedgerSMB::Sysconfig::latex} && $form->{media} ne 'email') {
+ if (%{LedgerSMB::Sysconfig::printer} && ${LedgerSMB::Sysconfig::latex} && $form->{media} ne 'email') {
print qq|
<td>|.$locale->text('Copies').qq|
<input name=copies size=2 value=$form->{copies}></td>
@@ -1926,7 +1926,7 @@
if ($form->{media} !~ /(screen|email)/) {
- $form->{OUT} = "| $printer{$form->{media}}";
+ $form->{OUT} = "| ${LedgerSMB::Sysconfig::printer}{$form->{media}}";
$form->{"$form->{ct}_id"} = "";
$SIG{INT} = 'IGNORE';
} else {
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.