summaryrefslogtreecommitdiff
path: root/LedgerSMB/AA.pm
diff options
context:
space:
mode:
authoreinhverfr <einhverfr@4979c152-3d1c-0410-bac9-87ea11338e46>2007-05-07 06:02:55 +0000
committereinhverfr <einhverfr@4979c152-3d1c-0410-bac9-87ea11338e46>2007-05-07 06:02:55 +0000
commit19b819c58c2bd54d1354c8004e680a40e9ae94ec (patch)
tree3b3a561235193818dad05bfe928b70ea651a3050 /LedgerSMB/AA.pm
parent1d4c913ccaf723b79d5a4dbd9fcbe9e4297ec9ad (diff)
Applying patch to bugs 1699718 and 1713439
git-svn-id: https://ledger-smb.svn.sourceforge.net/svnroot/ledger-smb/trunk@1146 4979c152-3d1c-0410-bac9-87ea11338e46
Diffstat (limited to 'LedgerSMB/AA.pm')
-rw-r--r--LedgerSMB/AA.pm8
1 files changed, 6 insertions, 2 deletions
diff --git a/LedgerSMB/AA.pm b/LedgerSMB/AA.pm
index dde35958..072e97d6 100644
--- a/LedgerSMB/AA.pm
+++ b/LedgerSMB/AA.pm
@@ -875,6 +875,7 @@ sub transactions {
$sth->execute(@paidargs) || $form->dberror($query);
while ( my $ref = $sth->fetchrow_hashref(NAME_lc) ) {
+ $form->db_parse_numeric(sth => $sth, hashref => $ref);
$ref->{exchangerate} = 1 unless $ref->{exchangerate};
if ( $ref->{linetotal} <= 0 ) {
@@ -963,7 +964,7 @@ sub get_name {
$sth->execute(@queryargs) || $form->dberror($query);
$ref = $sth->fetchrow_hashref(NAME_lc);
-
+ $form->db_parse_numeric(sth => $sth, hashref => $ref);
if ( $form->{id} ) {
for (qw(currency employee employee_id intnotes)) {
delete $ref->{$_};
@@ -1028,7 +1029,9 @@ sub get_name {
$sth = $dbh->prepare($query);
$sth->execute( $form->{"$form->{vc}_id"} ) || $form->dberror($query);
- while ( my ( $amount, $exch ) = $sth->fetchrow_array ) {
+ while ( my @ref = $sth->fetchrow_array ) {
+ $form->db_parse_numeric(sth => $sth, arrayref => \@ref);
+ my ($amount, $exch) = @ref;
$exch = 1 unless $exch;
$form->{creditremaining} -= $amount * $exch;
}
@@ -1099,6 +1102,7 @@ sub get_name {
my %a = ();
while ( $ref = $sth->fetchrow_hashref(NAME_lc) ) {
+ $form->db_parse_numeric(sth => $sth, hashref => $hashref);
if ( $tax{ $ref->{accno} } ) {
if ( not exists $a{ $ref->{accno} } ) {