From 05414f8898d711291f2b05944c1873dc9df2928d Mon Sep 17 00:00:00 2001 From: Laurent Destailleur Date: Thu, 3 Nov 2005 23:24:13 +0000 Subject: [PATCH] =?UTF-8?q?Fix:=20tva=20sur=20ajout=20ligne=20produit=20pr?= =?UTF-8?q?=E9d=E9finie?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- htdocs/facture.class.php | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/htdocs/facture.class.php b/htdocs/facture.class.php index d48b4c1001e..481ae3173d4 100644 --- a/htdocs/facture.class.php +++ b/htdocs/facture.class.php @@ -979,7 +979,8 @@ class Facture { $prod = new Product($this->db, $fk_product); $prod->fetch($fk_product); - $pu=$prod->price; + $pu=$prod->price; + $txtva=$prod->tva_tx; } $_price = $pu; $subprice = $pu; @@ -1015,8 +1016,8 @@ class Facture } // Formatage des prix - $_price = ereg_replace(',','.',$_price); - $subprice = ereg_replace(',','.',$subprice); + $_price = price2num($_price); + $subprice = price2num($subprice); $sql = 'INSERT INTO '.MAIN_DB_PREFIX.'facturedet '; $sql.= ' (fk_facture, description, price, qty, tva_taux, fk_product, remise_percent, subprice, remise, date_start, date_end, fk_code_ventilation, rang)';