[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

SF.net SVN: ledger-smb:[3936] branches/1.2/bin/aa.pl



Revision: 3936
          http://ledger-smb.svn.sourceforge.net/ledger-smb/?rev=3936&view=rev
Author:   einhverfr
Date:     2011-10-27 13:48:00 +0000 (Thu, 27 Oct 2011)
Log Message:
-----------
Correcting 1.2 bigfloat errors

Modified Paths:
--------------
    branches/1.2/bin/aa.pl

Modified: branches/1.2/bin/aa.pl
===================================================================
--- branches/1.2/bin/aa.pl	2011-10-27 13:34:43 UTC (rev 3935)
+++ branches/1.2/bin/aa.pl	2011-10-27 13:48:00 UTC (rev 3936)
@@ -44,7 +44,6 @@
 #
 #======================================================================
 
-use Math::BigFloat;
 use LedgerSMB::Tax;
 
 # any custom scripts for this one
@@ -1011,8 +1010,10 @@
     }
     $form->{paidaccounts} = $j;
     $form->{creditremaining} -=
-      ( $form->{invtotal} - Math::BigFloat->new($totalpaid) + $form->{oldtotalpaid} -
-          $form->{oldinvtotal} );
+      ( $form->parse_amount(\%myconfig, $form->{invtotal}) 
+      - $form->parse_amount(\%myconfig, $totalpaid) 
+      + $form->parse_amount(\%myconfig, $form->{oldtotalpaid}) 
+      - $form->parse_amount(\%myconfig,  $form->{oldinvtotal}) );
     $form->{oldinvtotal}  = $form->{invtotal};
     $form->{oldtotalpaid} = $totalpaid;
 

This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.