From 27e4c66dd5c91a926bf843d47c44d60402878e85 Mon Sep 17 00:00:00 2001 From: Laurent Destailleur Date: Sun, 24 Nov 2019 18:11:11 +0100 Subject: [PATCH 1/2] Fix empty --- htdocs/fourn/facture/card.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/htdocs/fourn/facture/card.php b/htdocs/fourn/facture/card.php index 1fd48033047..cba4a5f8b67 100644 --- a/htdocs/fourn/facture/card.php +++ b/htdocs/fourn/facture/card.php @@ -906,7 +906,7 @@ if (empty($reshook)) // FIXME Missing special_code into addline and updateline methods $object->special_code = $lines[$i]->special_code; - + // FIXME Missing $lines[$i]->ref_supplier and $lines[$i]->label into addline and updateline methods. They are filled when coming from order for example. $result = $object->addline( $desc, @@ -2643,7 +2643,7 @@ else if ($calculationrule == 'totalofround') $calculationrulenum=1; else $calculationrulenum=2; - if (empty($object->getVentilExportCompta())) { + if ($object->getVentilExportCompta() != 0) { $s=$langs->trans("ReCalculate").' '; $s.=''.$langs->trans("Mode1").''; $s.=' / '; From 98a7a5559fb0bd1a4777b3b5c5cbe8c439faf810 Mon Sep 17 00:00:00 2001 From: Laurent Destailleur Date: Sun, 24 Nov 2019 18:12:40 +0100 Subject: [PATCH 2/2] Fix bad fix --- htdocs/fourn/facture/card.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/htdocs/fourn/facture/card.php b/htdocs/fourn/facture/card.php index cba4a5f8b67..9933217a8bb 100644 --- a/htdocs/fourn/facture/card.php +++ b/htdocs/fourn/facture/card.php @@ -2643,7 +2643,7 @@ else if ($calculationrule == 'totalofround') $calculationrulenum=1; else $calculationrulenum=2; - if ($object->getVentilExportCompta() != 0) { + if ($object->getVentilExportCompta() == 0) { $s=$langs->trans("ReCalculate").' '; $s.=''.$langs->trans("Mode1").''; $s.=' / ';