Commit 1afbc4fa authored by Romain Bignon's avatar Romain Bignon

the reminder email is sent to 'maybe' users too

parent ff253eb2
......@@ -113,7 +113,7 @@ class Event(object):
def send_reminder(self, content):
for username, state in self.users.iteritems():
user =
if not user.exists or state != self.USER_CONFIRMED:
if not user.exists or state not in (self.USER_CONFIRMED, self.USER_MAYBE):
if not user.key:
......@@ -122,6 +122,8 @@ class Event(object):
url = build_url(build_root_url(,
self.f, user=user, use_key=True)
mail = user.new_mail('event-reminder.mail', 'Reminder of event')
mail.vars['event'] = self
mail.vars['user_state'] = state
mail.vars['realname'] = user.realname
mail.vars['content'] = content
mail.vars['url'] = url
Hi ${realname}!
% if user_state == event.USER_CONFIRMED:
You have confirmed the event "${event.title}" on ${'%A %d %B %Y, %H:%M') | h}.
% else:
You said you are not sure to come at the event "${event.title}" on ${'%A %d %B %Y, %H:%M') | h}.
% endif
The owner sends you this message:
% if user_state == event.USER_CONFIRMED:
To see the full event, follow this link:
% else:
To finally confirm or decline the event, follow this link:
% endif
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment