diff --git a/htdocs/admin/modules.php b/htdocs/admin/modules.php index abd6a3af5d1..25acfb51332 100644 --- a/htdocs/admin/modules.php +++ b/htdocs/admin/modules.php @@ -450,7 +450,7 @@ foreach ($orders as $key => $value) if (! empty($conf->global->$const_name)) { // Module actif - if (! empty($objMod->always_enabled) || ($conf->global->MAIN_MODULE_MULTICOMPANY && $conf->entity!=1 && $objMod->core_enabled)) print $langs->trans("Required"); + if (! empty($objMod->always_enabled) || (($conf->global->MAIN_MODULE_MULTICOMPANY && $objMod->core_enabled) && ($user->entity || $conf->entity!=1))) print $langs->trans("Required"); else print "numero."&action=reset&value=" . $modName . "&mode=" . $mode . "\">" . $langs->trans("Disable") . "\n"; if (! empty($objMod->config_page_url)) diff --git a/htdocs/includes/modules/modMultiCompany.class.php b/htdocs/includes/modules/modMultiCompany.class.php index b62869dc25b..da90459c218 100644 --- a/htdocs/includes/modules/modMultiCompany.class.php +++ b/htdocs/includes/modules/modMultiCompany.class.php @@ -57,7 +57,7 @@ class modMultiCompany extends DolibarrModules $this->name = preg_replace('/^mod/i','',get_class($this)); // Module description, used if translation string 'ModuleXXXDesc' not found (where XXX is value of numeric property 'numero' of module) $this->description = "Gestion Multi-Societe"; - // Can be enabled / disabled only in the main company + // Can be enabled / disabled only in the main company with superadmin account $this->core_enabled = 1; // Possible values for version are: 'development', 'experimental', 'dolibarr' or version $this->version = 'development';