summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authortetragon <tetragon@4979c152-3d1c-0410-bac9-87ea11338e46>2006-10-13 16:55:11 +0000
committertetragon <tetragon@4979c152-3d1c-0410-bac9-87ea11338e46>2006-10-13 16:55:11 +0000
commitef50db090dc34710f475d10f7caf9178761457c8 (patch)
tree318d490192932c098445473912329adcb2f21f91
parentf8af75401f81258ef0f5302808ff884a99c243c2 (diff)
Fix the array expansion in till closing
git-svn-id: https://ledger-smb.svn.sourceforge.net/svnroot/ledger-smb/trunk@211 4979c152-3d1c-0410-bac9-87ea11338e46
-rwxr-xr-xbin/rc.pl6
1 files changed, 3 insertions, 3 deletions
diff --git a/bin/rc.pl b/bin/rc.pl
index df3865b1..9e47abeb 100755
--- a/bin/rc.pl
+++ b/bin/rc.pl
@@ -250,7 +250,7 @@ function money_round(m){
function custom_calc_total(){
|;
my $subgen = 'document.forms[0].sub_sub.value = ';
- foreach my $unit ($pos_config{'breakdown'}) {
+ foreach my $unit (@{$pos_config{'breakdown'}}) {
# XXX Needs to take into account currencies that don't use 2 dp
my $parsed = $form->parse_amount(\%pos_config, $unit);
my $calcval = $parsed;
@@ -289,7 +289,7 @@ function check_errors(){
<table>
<col><col><col>|;
- foreach my $unit ($pos_config{'breakdown'}) {
+ foreach my $unit (@{$pos_config{'breakdown'}}) {
# XXX Needs to take into account currencies that don't use 2 dp
my $calcval = $form->parse_amount(\%pos_config, $unit);
$calcval = sprintf('%03d', $calcval * 100) if $calcval < 1;
@@ -381,7 +381,7 @@ sub close_till {
$head = "Closing Till $pos_config{till} for $form->{login}\n".
"Date: $form->{transdate}\n\n\n";
my @cashlines = [$locale->text("Cash Breakdown:")];
- foreach my $unit ($pos_config{'breakdown'}) {
+ foreach my $unit (@{$pos_config{'breakdown'}}) {
# XXX Needs to take into account currencies that don't use 2 dp
my $parsed = $form->parse_amount(\%pos_config, $unit);
my $calcval = $parsed;