Removing hardcoded BCC email list

This commit is contained in:
John Mullins
2024-02-25 23:51:47 +11:00
parent 67681eceff
commit 35692c0903
+2 -4
View File
@@ -39,9 +39,8 @@ def email_companies_bus_roll(request, query_set=None):
subject = "Echuca Schools Bus Roll"
message = f"A new bus roll for {company.name} has been generated"
email_from = "bus.manager@education.vic.gov.au"
bcc = "nicole.edwards4@education.vic.gov.au"
recipient = [company.contact_email]
email = EmailMessage(subject, message, email_from, recipient, bcc=bcc)
email = EmailMessage(subject, message, email_from, recipient)
email.attach(f"school_bus_roll_{date.today()}.pdf", pdf.content)
email.send(fail_silently=True)
@@ -67,9 +66,8 @@ def email_school_roll(request, query_set):
subject = "Echuca Schools Bus Roll"
message = f"A new bus roll for {school.name} has been generated"
email_from = "bus.manager@education.vic.gov.au"
bcc = "nicole.edwards4@education.vic.gov.au"
recipient = [school.email]
email = EmailMessage(subject, message, email_from, recipient, bcc=bcc)
email = EmailMessage(subject, message, email_from, recipient)
email.attach(f"school_bus_roll_{date.today()}.pdf", pdf.content)
email.send(fail_silently=True)