From edb3336aa7fc9baa9fbf1ce016e589d0498fdbff Mon Sep 17 00:00:00 2001 From: Hiroshi Miura Date: Fri, 12 Jun 2015 01:36:11 +0900 Subject: [PATCH 1/2] notify to multiple speakers Signed-off-by: Hiroshi Miura --- symposion/proposals/models.py | 1 + 1 file changed, 1 insertion(+) diff --git a/symposion/proposals/models.py b/symposion/proposals/models.py index 3c953c39..c81a0791 100644 --- a/symposion/proposals/models.py +++ b/symposion/proposals/models.py @@ -135,6 +135,7 @@ class ProposalBase(models.Model): return { "title": self.title, "speaker": self.speaker.name, + "speakers": ', '.join([x.name for x in self.speakers()]), "kind": self.kind.name, } From 3dd2f14f7293950ccc6129b3d53a0ff9405b02d1 Mon Sep 17 00:00:00 2001 From: Hiroshi Miura Date: Fri, 12 Jun 2015 08:04:22 +0900 Subject: [PATCH 2/2] multiple recipients for email Signed-off-by: Hiroshi Miura --- symposion/reviews/models.py | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/symposion/reviews/models.py b/symposion/reviews/models.py index b51ef2f0..1537ae98 100644 --- a/symposion/reviews/models.py +++ b/symposion/reviews/models.py @@ -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):