phpcompta-dev
[Top][All Lists]
Advanced

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

[Phpcompta-dev] r5177 - phpcompta/tags/rel650/include


From: phpcompta-dev
Subject: [Phpcompta-dev] r5177 - phpcompta/tags/rel650/include
Date: Wed, 6 Feb 2013 19:53:40 +0100 (CET)

Author: danydb
Date: 2013-02-06 19:53:39 +0100 (Wed, 06 Feb 2013)
New Revision: 5177

Modified:
   phpcompta/tags/rel650/include/class_acc_ledger.php
Log:
0000783: Apparence dans HISTO des notes

Modified: phpcompta/tags/rel650/include/class_acc_ledger.php
===================================================================
--- phpcompta/tags/rel650/include/class_acc_ledger.php  2013-02-06 18:34:25 UTC 
(rev 5176)
+++ phpcompta/tags/rel650/include/class_acc_ledger.php  2013-02-06 18:53:39 UTC 
(rev 5177)
@@ -930,7 +930,14 @@
                                $t_amount=$row['total_invoice'];
                        $tot = ($positive != 0) ? bcsub($tot , $t_amount ): 
bcadd($tot , $t_amount);
                        //STAN $positive always == 0
-                       $r.=( $positive != 0 ) ? "<font color=\"red\">  - " . 
nbm($t_amount) . "</font>" : nbm($t_amount);
+                       if ($row [ 'jrn_def_type']=='FIN')
+                       {
+                               $r.=( $positive != 0 ) ? "<font color=\"red\">  
- " . nbm($t_amount) . "</font>" : nbm($t_amount);
+                       }
+                       else
+                       {
+                               $r.=( $t_amount <  0 ) ? "<font color=\"red\">  
" . nbm($t_amount) . "</font>" : nbm($t_amount);
+                       }
                        $r.="</TD>";
 
 
@@ -946,9 +953,9 @@
                                $h->name = "set_jr_id" . $row['jr_id'];
                                $r.='<TD>' . $w->input() . $h->input() . 
'</TD>';
                                if ($row['jr_rapt'] == 'paid')
-                                       $amount_paid+=$row['jr_montant'];
+                                       
$amount_paid=bcadd($amount_paid,$t_amount);
                                else
-                                       $amount_unpaid+=$row['jr_montant'];
+                                       
$amount_unpaid=bcadd($amount_unpaid,$t_amount);
                        }
 
                        // Rapprochement



---
PhpCompta est un logiciel de comptabilité libre en ligne (full web)
Projet opensource http://www.phpcompta.eu



reply via email to

[Prev in Thread] Current Thread [Next in Thread]