diff --git a/htdocs/comm/pre.inc.php b/htdocs/comm/pre.inc.php index c1c13de1b561119f45b5fda43140535c4d20c3ec..8b76def8c9b7d9e38526b3395546f02d84a7d1e4 100644 --- a/htdocs/comm/pre.inc.php +++ b/htdocs/comm/pre.inc.php @@ -76,31 +76,31 @@ function llxHeader($head = "", $title = "") $menu->add_submenu(DOL_URL_ROOT."/comm/propal/stats/", $langs->trans("Statistics")); } - if ($conf->contrat->enabled) + if ($conf->contrat->enabled && $user->rights->contrat->lire) { $langs->load("contracts"); $menu->add(DOL_URL_ROOT."/contrat/index.php", $langs->trans("Contracts")); } - if ($conf->commande->enabled ) + if ($conf->commande->enabled && $user->rights->commande->lire) { $langs->load("orders"); $menu->add(DOL_URL_ROOT."/commande/index.php", $langs->trans("Orders")); } - if ($user->rights->mailing->lire) + if ($user->mailing->enabled && $user->rights->mailing->lire) { $langs->load("mails"); $menu->add(DOL_URL_ROOT."/comm/mailing/", $langs->trans("EMailings")); } - if ($conf->fichinter->enabled ) + if ($conf->fichinter->enabled && $user->rights->ficheinter->lire) { $langs->load("interventions"); $menu->add(DOL_URL_ROOT."/fichinter/index.php", $langs->trans("Interventions")); } - if ($conf->produit->enabled || $conf->service->enabled) + if (($conf->produit->enabled || $conf->service->enabled) && $user->rights->produit->lire) { $langs->load("products"); $chaine=""; @@ -110,7 +110,7 @@ function llxHeader($head = "", $title = "") $menu->add(DOL_URL_ROOT."/product/index.php", "$chaine"); } - if ($conf->projet->enabled ) + if ($conf->projet->enabled && $user->rights->projet->lire) { $langs->load("projects"); $menu->add(DOL_URL_ROOT."/projet/index.php", $langs->trans("Projects")); diff --git a/htdocs/commande/pre.inc.php b/htdocs/commande/pre.inc.php index 6b79f66b155fd950f7e4f6ecea1892c6801ad402..87caf434353d9a0d9fb718a6e69989f222dc1a93 100644 --- a/htdocs/commande/pre.inc.php +++ b/htdocs/commande/pre.inc.php @@ -48,7 +48,8 @@ function llxHeader($head = "", $title="", $help_url='') $menu->add_submenu(DOL_URL_ROOT."/commande/liste.php", $langs->trans("List")); $menu->add_submenu(DOL_URL_ROOT."/commande/stats/", $langs->trans("Statistics")); - if ($conf->expedition->enabled) { + if ($conf->expedition->enabled && $user->rights->expedition->lire) + { $menu->add(DOL_URL_ROOT."/expedition/", $langs->trans("Sendings")); } diff --git a/htdocs/includes/menus/barre_top/default.php b/htdocs/includes/menus/barre_top/default.php index 9f8f8a8caf2a52f28b0a438a685068d4ff8be7c8..3e020ecc85c751c08c4d64d29cbaaa939c4c7bb9 100644 --- a/htdocs/includes/menus/barre_top/default.php +++ b/htdocs/includes/menus/barre_top/default.php @@ -94,7 +94,7 @@ class MenuTop { print '<a class="tmenu" '.($id?'id="'.$id.'" ':'').'href="'.DOL_URL_ROOT.'/index.php?mainmenu=home&leftmenu="'.($this->atarget?" target=$this->atarget":"").'>'.$langs->trans("Home").'</a>'; // Entr�e adherent - if ($conf->adherent->enabled) + if ($conf->adherent->enabled && $user->rights->adherent->lire) { $langs->load("members"); diff --git a/htdocs/pre.inc.php b/htdocs/pre.inc.php index a8be3bb6ff0e63381288845e6599b08cebbae6a0..f52c7c68bb76f286fc5e0aa559cb21ba5ff9e9e9 100644 --- a/htdocs/pre.inc.php +++ b/htdocs/pre.inc.php @@ -56,7 +56,7 @@ function llxHeader($head = "") { $menu->add_submenu(DOL_URL_ROOT."/contact/index.php",$langs->trans("Contacts")); } - if ($conf->commercial->enabled && $user->rights->societe->lire) + if ($conf->commercial->enabled && $user->rights->commercial->lire) { $langs->load("commercial"); $menu->add(DOL_URL_ROOT."/comm/index.php",$langs->trans("Commercial")); @@ -71,7 +71,7 @@ function llxHeader($head = "") { } } - if ($conf->compta->enabled && $user->rights->societe->lire) + if ($conf->compta->enabled && $user->rights->general->lire) { $langs->load("compta"); $menu->add(DOL_URL_ROOT."/compta/index.php", $langs->trans("Accountancy")); @@ -168,7 +168,7 @@ function llxHeader($head = "") { $menu->add(DOL_URL_ROOT."/postnuke/articles/index.php", "Editorial"); } - if ($conf->bookmark->enabled && $user->rights->mailing->lire) + if ($conf->bookmark->enabled && $user->rights->bookmark->lire) { $menu->add(DOL_URL_ROOT."/bookmarks/liste.php", $langs->trans("Bookmarks")); }