Use isModEnabled

This commit is contained in:
Alexandre SPANGARO 2022-09-25 06:31:42 +02:00
parent 75ed50a53c
commit ab9dda0f93
5 changed files with 5 additions and 5 deletions

View File

@ -190,7 +190,7 @@ if ($object->id > 0) {
$help_url = 'EN:Module_Agenda_En';
llxHeader('', $title, $help_url);
if (!empty($conf->notification->enabled)) {
if (isModEnabled('notification')) {
$langs->load("mails");
}
$head = myobjectPrepareHead($object);

View File

@ -347,7 +347,7 @@ if ($object->id > 0 && (empty($action) || ($action != 'edit' && $action != 'crea
// Confirmation of action xxxx (You can use it for xxx = 'close', xxx = 'reopen', ...)
if ($action == 'xxx') {
$text = $langs->trans('ConfirmActionMyObject', $object->ref);
/*if (!empty($conf->notification->enabled))
/*if (isModEnabled('notification'))
{
require_once DOL_DOCUMENT_ROOT . '/core/class/notify.class.php';
$notify = new Notify($db);

View File

@ -134,7 +134,7 @@ if ($object->id > 0) {
$help_url = 'EN:Module_Agenda_En|FR:Module_Agenda|ES:Módulo_Agenda|DE:Modul_Agenda';
llxHeader('', $title, $help_url);
if (!empty($conf->notification->enabled)) {
if (isModEnabled('notification')) {
$langs->load("mails");
}
$head = moPrepareHead($object);

View File

@ -427,7 +427,7 @@ if ($object->id > 0 && (empty($action) || ($action != 'edit' && $action != 'crea
}
$text = $langs->trans('ConfirmValidateMo', $numref);
/*if (!empty($conf->notification->enabled))
/*if (isModEnabled('notification'))
{
require_once DOL_DOCUMENT_ROOT . '/core/class/notify.class.php';
$notify = new Notify($db);

View File

@ -473,7 +473,7 @@ if ($object->id > 0 && (empty($action) || ($action != 'edit' && $action != 'crea
}
$text = $langs->trans('ConfirmValidateMo', $numref);
/*if (!empty($conf->notification->enabled))
/*if (isModEnabled('notification'))
{
require_once DOL_DOCUMENT_ROOT . '/core/class/notify.class.php';
$notify = new Notify($db);