This commit is contained in:
Paula Quispe
2017-03-13 13:45:26 -04:00
parent 4c07012e19
commit 0e9258ec6f
3 changed files with 35 additions and 0 deletions

View File

@@ -5370,6 +5370,20 @@ class Cases
$fromName = $aConfiguration['MESS_FROM_NAME'];
$fromMail = $aConfiguration['MESS_FROM_MAIL'];
$from = $fromName . (($fromMail != '') ? ' <' . $fromMail . '>' : '');
//If the configuration was not configured correctly
if (empty($fromMail)) {
$dataLog = \Bootstrap::getDefaultContextLog();
$dataLog['appUid'] = $arrayData['APPLICATION'];
$dataLog['usrUid'] = $arrayData['USER_LOGGED'];
$dataLog['appNumber'] = $arrayData['APP_NUMBER'];
$dataLog['tasUid'] = $arrayData['TASK'];
$dataLog['proUid'] = $aTaskInfo['PRO_UID'];
$dataLog['appMessageStatus'] = 'pending';
$dataLog['subject'] = $sSubject;
$dataLog['from'] = $from;
$dataLog['action'] = G::LoadTranslation('ID_EMAIL_SERVER_FROM_MAIL_EMPTY');
Bootstrap::registerMonolog('EmailServer', 300, 'Email server', $dataLog, $dataLog['workspace'], 'processmaker.log');
}
}
$dataLastEmail['msgError'] = $msgError;
$dataLastEmail['configuration'] = $aConfiguration;
@@ -5438,6 +5452,20 @@ class Cases
$fromName = $aConfiguration['MESS_FROM_NAME'];
$fromMail = $aConfiguration['MESS_FROM_MAIL'];
$from = $fromName . (($fromMail != '') ? ' <' . $fromMail . '>' : '');
//If the configuration was not configured correctly
if (empty($fromMail)) {
$dataLog = \Bootstrap::getDefaultContextLog();
$dataLog['appUid'] = $arrayData['APPLICATION'];
$dataLog['usrUid'] = $arrayData['USER_LOGGED'];
$dataLog['appNumber'] = $arrayData['APP_NUMBER'];
$dataLog['tasUid'] = $arrayData['TASK'];
$dataLog['proUid'] = $aTaskInfo['PRO_UID'];
$dataLog['appMessageStatus'] = 'pending';
$dataLog['subject'] = $sSubject;
$dataLog['from'] = $from;
$dataLog['action'] = G::LoadTranslation('ID_EMAIL_SERVER_FROM_MAIL_EMPTY');
Bootstrap::registerMonolog('EmailServer', 300, 'Email server', $dataLog, $dataLog['workspace'], 'processmaker.log');
}
}
$dataLastEmail['msgError'] = $msgError;
$dataLastEmail['configuration'] = $aConfiguration;

View File

@@ -1525,6 +1525,12 @@ msgstr "Permissions"
msgid "Notification for task assignment"
msgstr "Notification for task assignment"
# TRANSLATION
# LABEL/ID_EMAIL_SERVER_FROM_MAIL_EMPTY
#: LABEL/ID_EMAIL_SERVER_FROM_MAIL_EMPTY
msgid "The email has not been sent because configuration email in the Email Server Settings (admin/settings/email) is empty. Please fill this information."
msgstr "The email has not been sent because configuration email in the Email Server Settings (admin/settings/email) is empty. Please fill this information."
# TRANSLATION
# LABEL/ID_PERMITIONS
#: LABEL/ID_PERMITIONS

View File

@@ -3380,6 +3380,7 @@ INSERT INTO TRANSLATION (TRN_CATEGORY,TRN_ID,TRN_LANG,TRN_VALUE,TRN_UPDATE_DATE
( 'LABEL','ID_PREFIX','en','Prefix','2014-01-15') ,
( 'LABEL','ID_AUTO_PREFIX','en','Auto Prefix','2014-01-15') ,
( 'LABEL','ID_NOTIFICATION_ERROR','en','A problem occurred while trying to send the Task Notification.','2014-10-21') ,
( 'LABEL','ID_EMAIL_SERVER_FROM_MAIL_EMPTY','en','The email has not been sent because configuration email in the Email Server Settings (admin/settings/email) is empty. Please fill this information.','2016-03-13') ,
( 'LABEL','ID_INVALID_APPLICATION_ID_MSG','en','An invalid application ID was stored for the session. <br/> This could have happened if you opened another case in a new tab or window. <br/> Please {0} the case.','2014-10-21') ,
( 'LABEL','ID_REOPEN','en','re-open','2014-01-15') ,
( 'LABEL','ID_HOST','en','Host','2014-01-15') ,