Fixed a bug that was causing multiple tender types to have a name like 'Check #'

git-svn-id: file:///svn-source/pmgr/branches/yafr_20090716@400 97e9348a-65ac-dc4b-aefc-98561f571b83
This commit is contained in:
abijah
2009-07-28 16:06:03 +00:00
parent 5446f6a266
commit 6cf6dda3f8

View File

@@ -1204,7 +1204,7 @@ foreach $row (@{query($sdbh, $query)}) {
$newdb{'lookup'}{'receipt'}{$row->{'ReceiptNum'}}{$row->{'PaymentType'}}{'credit_ledger_id'} $newdb{'lookup'}{'receipt'}{$row->{'ReceiptNum'}}{$row->{'PaymentType'}}{'credit_ledger_id'}
= $newdb{'lookup'}{'account'}{'A/R'}{'ledger_id'}; = $newdb{'lookup'}{'account'}{'A/R'}{'ledger_id'};
if ($SITELINK_ACCOUNT_TYPE{$row->{'PaymentType'}} == 'Check') { if ($SITELINK_ACCOUNT_TYPE{$row->{'PaymentType'}} eq 'Check') {
$newdb{'lookup'}{'receipt'}{$row->{'ReceiptNum'}}{$row->{'PaymentType'}}{'name'} $newdb{'lookup'}{'receipt'}{$row->{'ReceiptNum'}}{$row->{'PaymentType'}}{'name'}
= 'Check #' . $row->{'CheckNum'}; = 'Check #' . $row->{'CheckNum'};
$newdb{'lookup'}{'receipt'}{$row->{'ReceiptNum'}}{$row->{'PaymentType'}}{'data1'} $newdb{'lookup'}{'receipt'}{$row->{'ReceiptNum'}}{$row->{'PaymentType'}}{'data1'}
@@ -1216,8 +1216,8 @@ foreach $row (@{query($sdbh, $query)}) {
'type' => 'RECEIPT', 'type' => 'RECEIPT',
'stamp' => $stamp, 'stamp' => $stamp,
'customer_id' => undef, # Must be set later 'customer_id' => undef, # Must be set later
'account_id' => $newdb{'lookup'}{'account'}{'A/R'}{'account_id'}, 'account_id' => $newdb{'lookup'}{'receipt'}{$row->{'ReceiptNum'}}{$row->{'PaymentType'}}{'credit_account_id'},
'ledger_id' => $newdb{'lookup'}{'account'}{'A/R'}{'ledger_id'}, 'ledger_id' => $newdb{'lookup'}{'receipt'}{$row->{'ReceiptNum'}}{$row->{'PaymentType'}}{'credit_ledger_id'},
'crdr' => 'CREDIT', 'crdr' => 'CREDIT',
'comment' => "Receipt: $row->{'ReceiptNum'}; Type: $row->{'PaymentType'}", 'comment' => "Receipt: $row->{'ReceiptNum'}; Type: $row->{'PaymentType'}",
}); });
@@ -1313,7 +1313,7 @@ foreach $row (@{query($sdbh, $query)})
'customer_id' => $newdb{'lookup'}{'charge'}{$row->{'ChargeID'}}{'customer_id'}, 'customer_id' => $newdb{'lookup'}{'charge'}{$row->{'ChargeID'}}{'customer_id'},
'amount' => $reconcile_amount, 'amount' => $reconcile_amount,
'account_id' => $newdb{'lookup'}{'receipt'}{$row->{'ReceiptNum'}}{$row->{'PaymentType'}}{'credit_account_id'}, 'account_id' => $newdb{'lookup'}{'receipt'}{$row->{'ReceiptNum'}}{$row->{'PaymentType'}}{'debit_account_id'},
}; };
$row->{'ChargeID'} = undef $row->{'ChargeID'} = undef