Use isModEnabled
This commit is contained in:
parent
75ed50a53c
commit
ab9dda0f93
@ -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);
|
||||
|
||||
@ -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);
|
||||
|
||||
@ -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);
|
||||
|
||||
@ -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);
|
||||
|
||||
@ -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);
|
||||
|
||||
Loading…
Reference in New Issue
Block a user