multiple recipients for email

Signed-off-by: Hiroshi Miura <miurahr@linux.com>
This commit is contained in:
Hiroshi Miura 2015-06-12 08:04:22 +09:00
parent edb3336aa7
commit 3dd2f14f72

View file

@ -309,9 +309,13 @@ class ResultNotification(models.Model):
subject = models.CharField(max_length=100)
body = models.TextField()
def recipients(self):
for speaker in self.proposal.speakers():
yield speaker.email
@property
def email_args(self):
return (self.subject, self.body, self.from_address, [self.to_address])
return (self.subject, self.body, self.from_address, self.recipients())
def promote_proposal(proposal):