phpcompta-dev
[Top][All Lists]
Advanced

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

[Phpcompta-dev] r5152 - in phpcompta/tags/rel650/include: . template


From: phpcompta-dev
Subject: [Phpcompta-dev] r5152 - in phpcompta/tags/rel650/include: . template
Date: Sun, 11 Nov 2012 20:47:21 +0100 (CET)

Author: danydb
Date: 2012-11-11 20:47:20 +0100 (Sun, 11 Nov 2012)
New Revision: 5152

Modified:
   phpcompta/tags/rel650/include/class_acc_ledger_purchase.php
   phpcompta/tags/rel650/include/class_acc_ledger_sold.php
   phpcompta/tags/rel650/include/template/ledger_detail_ach.php
   phpcompta/tags/rel650/include/template/ledger_detail_ven.php
Log:
0000756: Achat ou vente pour rembourser de la TVA, marchandise ou quant. = 0

Modified: phpcompta/tags/rel650/include/class_acc_ledger_purchase.php
===================================================================
--- phpcompta/tags/rel650/include/class_acc_ledger_purchase.php 2012-10-30 
21:25:19 UTC (rev 5151)
+++ phpcompta/tags/rel650/include/class_acc_ledger_purchase.php 2012-11-11 
19:47:20 UTC (rev 5152)
@@ -342,14 +342,15 @@
             $tot_perso=0;
             $tot_tva_nd=0;
             $tot_tva_ndded=0;
+                       $tva=array();
             /* Save all the items without vat and no deductible vat and 
expense*/
             for ($i=0;$i< $nb_item;$i++)
             {
                                $n_both=0;
                 if ( strlen(trim(${'e_march'.$i})) == 0 ) continue;
-                if ( ${'e_march'.$i.'_price'} == 0 ) continue;
+           /*     if ( ${'e_march'.$i.'_price'} == 0 ) continue;
                 if ( ${'e_quant'.$i} == 0 ) continue;
-
+*/
                 /* First we save all the items without vat */
                 $fiche=new Fiche($this->db);
                 $fiche->get_by_qcode(${"e_march".$i});

Modified: phpcompta/tags/rel650/include/class_acc_ledger_sold.php
===================================================================
--- phpcompta/tags/rel650/include/class_acc_ledger_sold.php     2012-10-30 
21:25:19 UTC (rev 5151)
+++ phpcompta/tags/rel650/include/class_acc_ledger_sold.php     2012-11-11 
19:47:20 UTC (rev 5152)
@@ -275,13 +275,12 @@
             $tot_tva=0;
             $tot_debit=0;
             $this->db->start();
+                       $tva=array();
             /* Save all the items without vat */
             for ($i=0;$i< $nb_item;$i++)
             {
                                $n_both=0;
                 if ( strlen(trim(${'e_march'.$i})) == 0 ) continue;
-                if ( ${'e_march'.$i.'_price'} == 0 ) continue;
-                if ( ${'e_quant'.$i} == 0 ) continue;
 
                 /* First we save all the items without vat */
                 $fiche=new Fiche($this->db);

Modified: phpcompta/tags/rel650/include/template/ledger_detail_ach.php
===================================================================
--- phpcompta/tags/rel650/include/template/ledger_detail_ach.php        
2012-10-30 21:25:19 UTC (rev 5151)
+++ phpcompta/tags/rel650/include/template/ledger_detail_ach.php        
2012-11-11 19:47:20 UTC (rev 5152)
@@ -161,7 +161,8 @@
     }
     $row.=td($input->input().$hidden);
     $row.=td($sym_tva,'style="text-align:center"');
-       $pu=bcdiv($q['qp_price'],$q['qp_quantite']);
+       $pu=0;
+       if ( $q['qp_quantite'] != 0 ) 
$pu=bcdiv($q['qp_price'],$q['qp_quantite']);
     $row.=td(nbm($pu),'class="num"');
     $row.=td(nbm($q['qp_quantite']),'class="num"');
 

Modified: phpcompta/tags/rel650/include/template/ledger_detail_ven.php
===================================================================
--- phpcompta/tags/rel650/include/template/ledger_detail_ven.php        
2012-10-30 21:25:19 UTC (rev 5151)
+++ phpcompta/tags/rel650/include/template/ledger_detail_ven.php        
2012-11-11 19:47:20 UTC (rev 5152)
@@ -154,7 +154,8 @@
 
     $row.=td($input->input().$hidden);
     $sym_tva='';
-       $pu=bcdiv($q['qs_price'],$q['qs_quantite']);
+       $pu=0;
+       if ($q['qs_quantite'] != 0)     
$pu=bcdiv($q['qs_price'],$q['qs_quantite']);
     $row.=td(nbm($pu),'class="num"');
     $row.=td(nbm($q['qs_quantite']),'class="num"');
        $sym_tva='';



---
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]