mirror of
https://github.com/Dolibarr/dolibarr.git
synced 2026-02-08 00:52:01 +01:00
Use IsModEnabled
This commit is contained in:
@@ -34,12 +34,12 @@ require_once DOL_DOCUMENT_ROOT.'/core/lib/company.lib.php';
|
||||
require_once DOL_DOCUMENT_ROOT.'/core/class/extrafields.class.php';
|
||||
require_once DOL_DOCUMENT_ROOT.'/contact/class/contact.class.php';
|
||||
require_once DOL_DOCUMENT_ROOT.'/categories/class/categorie.class.php';
|
||||
if (!empty($conf->project->enabled)) {
|
||||
if (isModEnabled('project')) {
|
||||
include_once DOL_DOCUMENT_ROOT.'/projet/class/project.class.php';
|
||||
include_once DOL_DOCUMENT_ROOT.'/core/class/html.formprojet.class.php';
|
||||
include_once DOL_DOCUMENT_ROOT.'/core/lib/project.lib.php';
|
||||
}
|
||||
if (!empty($conf->contrat->enabled)) {
|
||||
if (isModEnabled('contrat')) {
|
||||
include_once DOL_DOCUMENT_ROOT.'/core/lib/contract.lib.php';
|
||||
include_once DOL_DOCUMENT_ROOT.'/contrat/class/contrat.class.php';
|
||||
include_once DOL_DOCUMENT_ROOT.'/core/class/html.formcontract.class.php';
|
||||
@@ -698,7 +698,7 @@ if (empty($reshook)) {
|
||||
$userstat = new User($db);
|
||||
$form = new Form($db);
|
||||
$formticket = new FormTicket($db);
|
||||
if (!empty($conf->project->enabled)) {
|
||||
if (isModEnabled('project')) {
|
||||
$formproject = new FormProjets($db);
|
||||
}
|
||||
|
||||
@@ -940,7 +940,7 @@ if ($action == 'create' || $action == 'presend') {
|
||||
}
|
||||
|
||||
// Thirdparty
|
||||
if (!empty($conf->societe->enabled)) {
|
||||
if (isModEnabled('societe')) {
|
||||
$morehtmlref .= '<br>'.$langs->trans('ThirdParty').' ';
|
||||
if ($action != 'editcustomer' && $object->status < 8 && !$user->socid && $user->rights->ticket->write) {
|
||||
$morehtmlref .= '<a class="editfielda" href="'.$url_page_current.'?action=editcustomer&token='.newToken().'&track_id='.$object->track_id.'">'.img_edit($langs->transnoentitiesnoconv('Edit'), 0).'</a> : ';
|
||||
@@ -953,7 +953,7 @@ if ($action == 'create' || $action == 'presend') {
|
||||
}
|
||||
|
||||
// Project
|
||||
if (!empty($conf->project->enabled)) {
|
||||
if (isModEnabled('project')) {
|
||||
$langs->load("projects");
|
||||
$morehtmlref .= '<br>'.$langs->trans('Project').' ';
|
||||
if ($user->rights->ticket->write) {
|
||||
@@ -1107,7 +1107,7 @@ if ($action == 'create' || $action == 'presend') {
|
||||
print '</tr>';
|
||||
|
||||
// Timing (Duration sum of linked fichinter)
|
||||
if (!empty($conf->ficheinter->enabled)) {
|
||||
if (isModEnabled('ficheinter')) {
|
||||
$object->fetchObjectLinked();
|
||||
$num = count($object->linkedObjects);
|
||||
$timing = 0;
|
||||
|
||||
Reference in New Issue
Block a user