mirror of
https://github.com/Dolibarr/dolibarr.git
synced 2025-02-20 13:46:52 +01:00
Fix: regression
This commit is contained in:
parent
226901a7b9
commit
d7205fe627
|
|
@ -26,24 +26,12 @@
|
|||
*/
|
||||
|
||||
require("../main.inc.php");
|
||||
if (! empty($dolibarr_allow_overwritekernel))
|
||||
{
|
||||
require_once("html.formfile.class.php");
|
||||
require_once("client.class.php");
|
||||
require_once("actioncomm.class.php");
|
||||
require_once("agenda.lib.php");
|
||||
if ($conf->contrat->enabled) require_once("contrat/contrat.class.php");
|
||||
if ($conf->propal->enabled) require_once("comm/propal/propal.class.php");
|
||||
}
|
||||
else
|
||||
{
|
||||
require_once(DOL_DOCUMENT_ROOT."/html.formfile.class.php");
|
||||
require_once(DOL_DOCUMENT_ROOT."/client.class.php");
|
||||
require_once(DOL_DOCUMENT_ROOT."/actioncomm.class.php");
|
||||
require_once(DOL_DOCUMENT_ROOT."/agenda.lib.php");
|
||||
if ($conf->contrat->enabled) require_once(DOL_DOCUMENT_ROOT."/contrat/contrat.class.php");
|
||||
if ($conf->propal->enabled) require_once(DOL_DOCUMENT_ROOT."/comm/propal/propal.class.php");
|
||||
}
|
||||
require_once(DOL_DOCUMENT_ROOT."/html.formfile.class.php");
|
||||
require_once(DOL_DOCUMENT_ROOT."/client.class.php");
|
||||
require_once(DOL_DOCUMENT_ROOT."/actioncomm.class.php");
|
||||
require_once(DOL_DOCUMENT_ROOT."/agenda.lib.php");
|
||||
if ($conf->contrat->enabled) require_once(DOL_DOCUMENT_ROOT."/contrat/contrat.class.php");
|
||||
if ($conf->propal->enabled) require_once(DOL_DOCUMENT_ROOT."/comm/propal/propal.class.php");
|
||||
|
||||
if (!$user->rights->societe->lire)
|
||||
accessforbidden();
|
||||
|
|
|
|||
|
|
@ -57,7 +57,6 @@ class Conf
|
|||
var $tabs_modules = array();
|
||||
var $need_smarty = array();
|
||||
var $modules = array();
|
||||
var $include_path = array();
|
||||
|
||||
var $logbuffer = array();
|
||||
|
||||
|
|
@ -81,13 +80,6 @@ class Conf
|
|||
function setValues($db)
|
||||
{
|
||||
dol_syslog("Conf::setValues");
|
||||
|
||||
// Add root path
|
||||
$this->include_path[] = DOL_DOCUMENT_ROOT."/";
|
||||
// Add core path
|
||||
$this->include_path[] = DOL_DOCUMENT_ROOT."/core/";
|
||||
// Add library path
|
||||
$this->include_path[] = DOL_DOCUMENT_ROOT."/lib/";
|
||||
|
||||
// Avoid warning if not defined
|
||||
if (empty($this->db->dolibarr_main_db_encryption)) $this->db->dolibarr_main_db_encryption=0;
|
||||
|
|
@ -167,25 +159,12 @@ class Conf
|
|||
$this->$module->enabled=true;
|
||||
// Add this module in list of enabled modules
|
||||
$this->modules[]=$module;
|
||||
// Add class path
|
||||
if (file_exists(DOL_DOCUMENT_ROOT.'/'.$module.'/class/'))
|
||||
{
|
||||
$this->include_path[] = DOL_DOCUMENT_ROOT.'/'.$module.'/class/';
|
||||
}
|
||||
// Add library path
|
||||
if (file_exists(DOL_DOCUMENT_ROOT.'/'.$module.'/lib/'))
|
||||
{
|
||||
$this->include_path[] = DOL_DOCUMENT_ROOT.'/'.$module.'/lib/';
|
||||
}
|
||||
}
|
||||
}
|
||||
$i++;
|
||||
}
|
||||
}
|
||||
$db->free($result);
|
||||
|
||||
// Set include_path
|
||||
set_include_path(implode(PATH_SEPARATOR, $this->include_path));
|
||||
|
||||
// Clean some variables
|
||||
// conf->menu_top et conf->menu_left are defined in main.inc.php (according to user choice)
|
||||
|
|
|
|||
|
|
@ -24,9 +24,9 @@
|
|||
*/
|
||||
|
||||
require("../../main.inc.php");
|
||||
require_once("multicompany.class.php");
|
||||
require_once("admin.lib.php");
|
||||
require_once("company.lib.php");
|
||||
require_once(DOL_DOCUMENT_ROOT."/multicompany/class/multicompany.class.php");
|
||||
require_once(DOL_DOCUMENT_ROOT."/lib/admin.lib.php");
|
||||
require_once(DOL_DOCUMENT_ROOT."/lib/company.lib.php");
|
||||
|
||||
$langs->load("admin");
|
||||
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user