From fb4ed77d93af6f9686e5a1e1c4ea70f3657e8c5a Mon Sep 17 00:00:00 2001 From: Regis Houssin Date: Sun, 8 Oct 2023 21:05:46 +0200 Subject: [PATCH] FIX avoid warning if module not activated --- htdocs/core/boxes/box_graph_product_distribution.php | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/htdocs/core/boxes/box_graph_product_distribution.php b/htdocs/core/boxes/box_graph_product_distribution.php index e0e1498824a..7c9e88239fe 100644 --- a/htdocs/core/boxes/box_graph_product_distribution.php +++ b/htdocs/core/boxes/box_graph_product_distribution.php @@ -393,15 +393,15 @@ class box_graph_product_distribution extends ModeleBoxes } if ($nbofgraph == 2) { $stringtoshow .= '
'; - if ($showpropalnb) { + if (isModEnabled('propal') && $showpropalnb) { $stringtoshow .= $px2->show(); - } elseif ($showordernb) { + } elseif (isModEnabled('commande') && $showordernb) { $stringtoshow .= $px3->show(); } $stringtoshow .= '
'; - if ($showinvoicenb) { + if (isModEnabled('facture') && $showinvoicenb) { $stringtoshow .= $px1->show(); - } elseif ($showordernb) { + } elseif (isModEnabled('commande') && $showordernb) { $stringtoshow .= $px3->show(); } $stringtoshow .= '
';