From 9da2441f8f0cee41f0631fa04e8f913141f88c48 Mon Sep 17 00:00:00 2001 From: Rodolphe Quiedeville Date: Tue, 12 Aug 2003 18:01:03 +0000 Subject: [PATCH] pfffff --- htdocs/includes/menus/barre_top/default.php | 101 ++++++++++++-------- 1 file changed, 60 insertions(+), 41 deletions(-) diff --git a/htdocs/includes/menus/barre_top/default.php b/htdocs/includes/menus/barre_top/default.php index 9d211e10359..95c274abe69 100644 --- a/htdocs/includes/menus/barre_top/default.php +++ b/htdocs/includes/menus/barre_top/default.php @@ -20,56 +20,75 @@ * */ -if (strstr($GLOBALS["SCRIPT_URL"],DOL_URL_ROOT.'/comm/')) +if (defined('MAIN_MODULE_COMMERCIAL') && MAIN_MODULE_COMMERCIAL == 1) { - print ''; - if ($user->comm > 0 && $conf->commercial ) + if (strstr($GLOBALS["SCRIPT_URL"],DOL_URL_ROOT.'/comm/')) { - print 'Commercial'; + print ''; + if ($user->comm > 0 && $conf->commercial ) + { + print 'Commercial'; + } + else + { + print '-'; + } } else { - print '-'; + print ''; + if ($user->comm > 0 && $conf->commercial ) + { + print 'Commercial'; + } + else + { + print '-'; + } + } +} +elseif (defined('MAIN_MODULE_ADHERENT') && MAIN_MODULE_ADHERENT == 1) +{ + print ''; + print 'Adhérents'; +} +else +{ + print '-'; +} + + +if (defined('MAIN_MODULE_COMPTABILITE') && MAIN_MODULE_COMPTABILITE == 1) +{ + if (strstr($GLOBALS["SCRIPT_URL"],DOL_URL_ROOT.'/compta/')) + { + print ''; + if ($user->compta > 0) + { + print 'Compta'; + } + else + { + print '-'; + } + } + else + { + + print ''; + if ($user->compta > 0) + { + print 'Compta'; + } + else + { + print '-'; + } } } else { - print ''; - if ($user->comm > 0 && $conf->commercial ) - { - print 'Commercial'; - } - else - { - print '-'; - } -} - - -if (strstr($GLOBALS["SCRIPT_URL"],DOL_URL_ROOT.'/compta/')) -{ - print ''; - if ($user->compta > 0) - { - print 'Compta'; - } - else - { - print '-'; - } -} -else -{ - - print ''; - if ($user->compta > 0) - { - print 'Compta'; - } - else - { - print '-'; - } + print '-'; } if (strstr($GLOBALS["SCRIPT_URL"],DOL_URL_ROOT.'/product/'))