Use isModEnabled
This commit is contained in:
parent
ccea57423a
commit
eae6118d40
@ -35,7 +35,7 @@ require_once DOL_DOCUMENT_ROOT.'/core/lib/files.lib.php';
|
|||||||
require_once DOL_DOCUMENT_ROOT.'/core/class/html.formfile.class.php';
|
require_once DOL_DOCUMENT_ROOT.'/core/class/html.formfile.class.php';
|
||||||
require_once DOL_DOCUMENT_ROOT.'/core/lib/salaries.lib.php';
|
require_once DOL_DOCUMENT_ROOT.'/core/lib/salaries.lib.php';
|
||||||
require_once DOL_DOCUMENT_ROOT.'/salaries/class/salary.class.php';
|
require_once DOL_DOCUMENT_ROOT.'/salaries/class/salary.class.php';
|
||||||
if (!empty($conf->project->enabled)) {
|
if (isModEnabled('project')) {
|
||||||
require_once DOL_DOCUMENT_ROOT.'/projet/class/project.class.php';
|
require_once DOL_DOCUMENT_ROOT.'/projet/class/project.class.php';
|
||||||
require_once DOL_DOCUMENT_ROOT.'/core/class/html.formprojet.class.php';
|
require_once DOL_DOCUMENT_ROOT.'/core/class/html.formprojet.class.php';
|
||||||
}
|
}
|
||||||
@ -132,7 +132,7 @@ if ($action == 'setlabel' && $user->rights->salaries->write) {
|
|||||||
*/
|
*/
|
||||||
|
|
||||||
$form = new Form($db);
|
$form = new Form($db);
|
||||||
if (!empty($conf->project->enabled)) $formproject = new FormProjets($db);
|
if (isModEnabled('projet')) $formproject = new FormProjets($db);
|
||||||
|
|
||||||
$title = $langs->trans('Salary')." - ".$langs->trans('Documents');
|
$title = $langs->trans('Salary')." - ".$langs->trans('Documents');
|
||||||
$help_url = "";
|
$help_url = "";
|
||||||
@ -176,7 +176,7 @@ if ($object->id) {
|
|||||||
$morehtmlref .= '<br>'.$langs->trans('Employee').' : '.$userstatic->getNomUrl(-1);
|
$morehtmlref .= '<br>'.$langs->trans('Employee').' : '.$userstatic->getNomUrl(-1);
|
||||||
|
|
||||||
// Project
|
// Project
|
||||||
if (!empty($conf->project->enabled)) {
|
if (isModEnabled('projet')) {
|
||||||
$morehtmlref .= '<br>'.$langs->trans('Project').' ';
|
$morehtmlref .= '<br>'.$langs->trans('Project').' ';
|
||||||
if ($user->rights->salaries->write) {
|
if ($user->rights->salaries->write) {
|
||||||
if ($action != 'classify') {
|
if ($action != 'classify') {
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user