From 1ab949b3c45b72c34713aef6ece166936092cfab Mon Sep 17 00:00:00 2001 From: Philippe GRAND Date: Wed, 31 Aug 2022 21:48:32 +0200 Subject: [PATCH] update code --- htdocs/comm/action/card.php | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/htdocs/comm/action/card.php b/htdocs/comm/action/card.php index 6f6ddc5383e..380c5813155 100644 --- a/htdocs/comm/action/card.php +++ b/htdocs/comm/action/card.php @@ -1411,7 +1411,7 @@ if ($action == 'create') { } // Project - if (!empty($conf->project->enabled)) { + if (isModEnabled('project')) { $langs->load("projects"); $projectid = GETPOST('projectid', 'int'); @@ -1914,7 +1914,7 @@ if ($id > 0) { } // Project - if (!empty($conf->project->enabled)) { + if (isModEnabled('project')) { $langs->load("projects"); print ''.$langs->trans("Project").''; @@ -1939,7 +1939,7 @@ if ($id > 0) { print ''; print ''.$langs->trans("LinkedObject").''; - if ($object->elementtype == 'task' && !empty($conf->project->enabled)) { + if ($object->elementtype == 'task' && isModEnabled('project')) { print ''; $urloption = '?action=create&donotclearsession=1'; // we use create not edit for more flexibility @@ -2132,7 +2132,7 @@ if ($id > 0) { // Thirdparty //$morehtmlref.='
'.$langs->trans('ThirdParty') . ' : ' . $object->thirdparty->getNomUrl(1); // Project - if (!empty($conf->project->enabled)) { + if (isModEnabled('project')) { $langs->load("projects"); //$morehtmlref.='
'.$langs->trans('Project') . ' '; $morehtmlref .= $langs->trans('Project').' ';