|
@@ -48,11 +48,14 @@ if ($action == 'setvalue')
|
|
|
$mailerror = GETPOST('MAILING_EMAIL_ERRORSTO','alpha');
|
|
|
$checkread = GETPOST('value','alpha');
|
|
|
$checkread_key = GETPOST('MAILING_EMAIL_UNSUBSCRIBE_KEY','alpha');
|
|
|
+ $mailingdelay = GETPOST('MAILING_DELAY', 'int');
|
|
|
|
|
|
$res=dolibarr_set_const($db, "MAILING_EMAIL_FROM",$mailfrom,'chaine',0,'',$conf->entity);
|
|
|
if (! $res > 0) $error++;
|
|
|
$res=dolibarr_set_const($db, "MAILING_EMAIL_ERRORSTO",$mailerror,'chaine',0,'',$conf->entity);
|
|
|
if (! $res > 0) $error++;
|
|
|
+ $res=dolibarr_set_const($db, "MAILING_DELAY",$mailingdelay,'chaine',0,'',$conf->entity);
|
|
|
+ if (! $res > 0) $error++;
|
|
|
|
|
|
// Create temporary encryption key if nedded
|
|
|
$res=dolibarr_set_const($db, "MAILING_EMAIL_UNSUBSCRIBE_KEY",$checkread_key,'chaine',0,'',$conf->entity);
|
|
@@ -124,6 +127,12 @@ print '<input size="32" type="text" name="MAILING_EMAIL_ERRORSTO" value="'.$conf
|
|
|
if (!empty($conf->global->MAILING_EMAIL_ERRORSTO) && ! isValidEmail($conf->global->MAILING_EMAIL_ERRORSTO)) print ' '.img_warning($langs->trans("BadEMail"));
|
|
|
print '</td></tr>';
|
|
|
|
|
|
+$var=!$var;
|
|
|
+print '<tr '.$bc[$var].'><td>';
|
|
|
+print $langs->trans("MailingDelay").'</td><td>';
|
|
|
+print '<input size="32" type="text" name="MAILING_DELAY" value="'.$conf->global->MAILING_DELAY.'">';
|
|
|
+print '</td></tr>';
|
|
|
+
|
|
|
// Constant to add salt into the unsubscribe and check read tag.
|
|
|
// It is also used as a security key parameter.
|
|
|
$var=!$var;
|