From d4a19e5968427457a0f1132da545da422e1e7e81 Mon Sep 17 00:00:00 2001 From: lvessiller Date: Mon, 28 Dec 2020 16:20:59 +0100 Subject: [PATCH] NEW add total margin in invoice list --- htdocs/compta/facture/list.php | 2 ++ 1 file changed, 2 insertions(+) diff --git a/htdocs/compta/facture/list.php b/htdocs/compta/facture/list.php index c61bfdf6819..a1bde7e4f3d 100644 --- a/htdocs/compta/facture/list.php +++ b/htdocs/compta/facture/list.php @@ -1584,6 +1584,8 @@ if ($resql) { print ''.price($marginInfo['total_margin']).''; if (!$i) $totalarray['nbfield']++; + if (!$i) $totalarray['pos'][$totalarray['nbfield']] = 'total_margin'; + $totalarray['val']['total_margin'] += $marginInfo['total_margin']; } // Total margin rate if (!empty($arrayfields['total_margin_rate']['checked']))