From 1831b46bae450b25efd66144dbc41f1972f62208 Mon Sep 17 00:00:00 2001 From: Laurent Destailleur Date: Tue, 17 Jul 2012 14:30:10 +0200 Subject: [PATCH] Fix: Do not show if module disabled --- htdocs/core/class/commonobject.class.php | 3 +++ 1 file changed, 3 insertions(+) diff --git a/htdocs/core/class/commonobject.class.php b/htdocs/core/class/commonobject.class.php index 2432a9524d4..31125a8eadc 100644 --- a/htdocs/core/class/commonobject.class.php +++ b/htdocs/core/class/commonobject.class.php @@ -2408,12 +2408,15 @@ abstract class CommonObject // To work with non standard path if ($objecttype == 'facture') { $tplpath = 'compta/'.$element; + if (empty($conf->facture->enabled)) continue; // Do not show if module disabled } else if ($objecttype == 'propal') { $tplpath = 'comm/'.$element; + if (empty($conf->propal->enabled)) continue; // Do not show if module disabled } else if ($objecttype == 'shipping') { $tplpath = 'expedition'; + if (empty($conf->expedition->enabled)) continue; // Do not show if module disabled } else if ($objecttype == 'delivery') { $tplpath = 'livraison';