Private
Public Access
1
0

automatic expiry of non-recurring users

This commit is contained in:
Sander Roosendaal
2018-11-27 12:29:30 +01:00
parent 72743fed0e
commit e0303b90b6
6 changed files with 83 additions and 2 deletions

View File

@@ -59,8 +59,12 @@ def send_template_email(from_email,to_email,subject,
html_content = htmly.render(context)
text_content = textify(html_content)
if 'cc' in kwargs:
msg = EmailMultiAlternatives(subject, text_content, from_email, to_email,cc=kwargs['cc'])
else:
msg = EmailMultiAlternatives(subject, text_content, from_email, to_email)
msg = EmailMultiAlternatives(subject, text_content, from_email, to_email)
msg.attach_alternative(html_content, "text/html")
if 'attach_file' in kwargs:
@@ -82,6 +86,8 @@ def send_template_email(from_email,to_email,subject,
else:
emailbounced = False
if not emailbounced:
res = msg.send()
else: