Updated default backend setting and enabled default sender setting

This commit is contained in:
eeintech 2021-04-21 09:28:30 -04:00
parent 8d8ef22b8d
commit ee3f3c7960
2 changed files with 8 additions and 2 deletions

View File

@ -512,8 +512,8 @@ EXCHANGE_BACKEND = 'InvenTree.exchange.InvenTreeManualExchangeBackend'
email_config = CONFIG.get('email', {})
EMAIL_BACKEND = get_setting(
'django.core.mail.backends.smtp.EmailBackend',
email_config.get('backend', '')
'INVENTREE_EMAIL_BACKEND',
email_config.get('backend', 'django.core.mail.backends.smtp.EmailBackend')
)
# Email backend settings
@ -537,6 +537,11 @@ EMAIL_HOST_PASSWORD = get_setting(
email_config.get('password', ''),
)
DEFAULT_FROM_EMAIL = get_setting(
'INVENTREE_EMAIL_SENDER',
email_config.get('sender', ''),
)
EMAIL_SUBJECT_PREFIX = '[InvenTree] '
EMAIL_USE_LOCALTIME = False

View File

@ -85,6 +85,7 @@ email:
port: 25
username: ''
password: ''
sender: ''
tls: False
ssl: False