From f9f1f92d86544b78e49c7f24759ae85862518cc8 Mon Sep 17 00:00:00 2001 From: Laurent Destailleur Date: Tue, 22 Nov 2016 19:45:06 +0100 Subject: [PATCH] FIX #6025 --- htdocs/fourn/class/fournisseur.commande.class.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/htdocs/fourn/class/fournisseur.commande.class.php b/htdocs/fourn/class/fournisseur.commande.class.php index e1d73ec6e09..e298ab43467 100644 --- a/htdocs/fourn/class/fournisseur.commande.class.php +++ b/htdocs/fourn/class/fournisseur.commande.class.php @@ -2288,10 +2288,10 @@ class CommandeFournisseur extends CommonOrder // Clean vat code $vat_src_code=''; - if (preg_match('/\((.*)\)/', $vatrate, $reg)) + if (preg_match('/\((.*)\)/', $txtva, $reg)) { $vat_src_code = $reg[1]; - $vatrate = preg_replace('/\s*\(.*\)/', '', $vatrate); // Remove code into vatrate. + $vatrate = preg_replace('/\s*\(.*\)/', '', $txtva); // Remove code into vatrate. } $tabprice=calcul_price_total($qty, $pu, $remise_percent, $txtva, $txlocaltax1, $txlocaltax2, 0, $price_base_type, $info_bits, $type, $this->thirdparty, $localtaxes_type, 100, $this->multicurrency_tx);