diff --git a/front/plugins/_publisher_email/config.json b/front/plugins/_publisher_email/config.json index 69fabbbf..387c8d7a 100755 --- a/front/plugins/_publisher_email/config.json +++ b/front/plugins/_publisher_email/config.json @@ -642,7 +642,7 @@ { "elementType": "input", "elementOptions": [], "transformers": [] } ] }, - "default_value": "user@gmail.com", + "default_value": "to@email.com", "options": [], "localized": ["name", "description"], "name": [ @@ -674,7 +674,31 @@ { "elementType": "input", "elementOptions": [], "transformers": [] } ] }, - "default_value": "NetAlertX ", + "default_value": "NetAlertX ", + "options": [], + "localized": ["name", "description"], + "name": [ + { + "language_code": "en_us", + "string": "From email" + } + ], + "description": [ + { + "language_code": "en_us", + "string": "From which email the notification is sent Name <email>. Some SMTP servers need this to be an email only." + } + ] + }, + { + "function": "SUBJECT", + "type": { + "dataType": "string", + "elements": [ + { "elementType": "input", "elementOptions": [], "transformers": [] } + ] + }, + "default_value": "NetAlertX Report", "options": [], "localized": ["name", "description"], "name": [ @@ -690,7 +714,7 @@ "description": [ { "language_code": "en_us", - "string": "Notification email subject line. Some SMTP servers need this to be an email." + "string": "Notification email subject line." }, { "language_code": "es_es", diff --git a/front/plugins/_publisher_email/email_smtp.py b/front/plugins/_publisher_email/email_smtp.py index 4bea52c8..682bf5ce 100755 --- a/front/plugins/_publisher_email/email_smtp.py +++ b/front/plugins/_publisher_email/email_smtp.py @@ -115,8 +115,7 @@ def send(pHTML, pText): mylog('debug', [f'[{pluginName}] SMTP_REPORT_TO: {hide_email(str(get_setting_value("SMTP_REPORT_TO")))} SMTP_USER: {hide_email(str(get_setting_value("SMTP_USER")))}']) - - subject, from_email, to_email, message_html, message_text = sanitize_email_content('NetAlertX Report', get_setting_value("SMTP_REPORT_FROM"), get_setting_value("SMTP_REPORT_TO"), pHTML, pText) + subject, from_email, to_email, message_html, message_text = sanitize_email_content(str(get_setting_value("SMTP_SUBJECT")), get_setting_value("SMTP_REPORT_FROM"), get_setting_value("SMTP_REPORT_TO"), pHTML, pText) emails = []