summaryrefslogtreecommitdiff
path: root/bin/pos.pl
diff options
context:
space:
mode:
authoreinhverfr <einhverfr@4979c152-3d1c-0410-bac9-87ea11338e46>2006-10-24 04:08:32 +0000
committereinhverfr <einhverfr@4979c152-3d1c-0410-bac9-87ea11338e46>2006-10-24 04:08:32 +0000
commit308307e013604d41e1c623e85d4c38c2c29a0597 (patch)
tree4f1dfe143d2d541826146bfcd78aee004569cd83 /bin/pos.pl
parent04fce104fb69421a95b8166750f84c184ff9d932 (diff)
Some tuning to the POS interface-- will add cc interface tomorrow.
git-svn-id: https://ledger-smb.svn.sourceforge.net/svnroot/ledger-smb/trunk@285 4979c152-3d1c-0410-bac9-87ea11338e46
Diffstat (limited to 'bin/pos.pl')
-rwxr-xr-xbin/pos.pl17
1 files changed, 15 insertions, 2 deletions
diff --git a/bin/pos.pl b/bin/pos.pl
index 999e0aa3..248d7731 100755
--- a/bin/pos.pl
+++ b/bin/pos.pl
@@ -405,7 +405,7 @@ sub form_footer {
|;
}
- @column_index = qw(paid source memo AR_paid);
+ @column_index = qw(paid memo source AR_paid);
$column_data{paid} = "<th>".$locale->text('Amount')."</th>";
$column_data{source} = "<th>".$locale->text('Source')."</th>";
@@ -431,6 +431,14 @@ sub form_footer {
$totalpaid = 0;
$form->{paidaccounts}++ if ($form->{"paid_$form->{paidaccounts}"});
+
+ my $memoselect = qq|<SELECT name="MEMONAME">|;
+ for (keys %pos_sources){
+ $memoselect .= qq|<option value="$_">$pos_sources{$_}</option>|;
+ }
+ $memoselect .= qq|</SELECT>|;
+
+
for $i (1 .. $form->{paidaccounts}) {
$form->{"selectAR_paid_$i"} = $form->{selectAR_paid};
@@ -448,7 +456,12 @@ sub form_footer {
}
$column_data{source} = qq|<td><input name="source_$i" size=10 value="$form->{"source_$i"}"></td>|;
- $column_data{memo} = qq|<td><input name="memo_$i" size=10 value="$form->{"memo_$i"}"></td>|;
+ $column_data{memo} = qq|<td>$memoselect</td>|;
+ $column_data{memo} =~ s/MEMONAME/memo_$i/;
+ if ($form->{"memo_$i"}){
+ my $memval = $form->{"memo_$i"};
+ $column_data{memo} =~ s/(option value="$memval")/$1 SELECTED/;
+ }
if ($pos_config{"coa_prefix"}){
if (!$form->{"AR_paid_$i"}){