diff options
author | Leif Johansson <leifj@sunet.se> | 2010-08-04 15:47:18 +0200 |
---|---|---|
committer | Leif Johansson <leifj@sunet.se> | 2010-08-04 15:47:18 +0200 |
commit | ecfa4c3677aad4db9d52c45c23043c62da569386 (patch) | |
tree | 33d2ba697c6b636dc8308fc810452d54ba0714ce | |
parent | 1f740b0af0de304c764e62fc0087c3bab6ae6bcf (diff) |
actually send email
-rw-r--r-- | coip/apps/invitation/models.py | 33 |
1 files changed, 16 insertions, 17 deletions
diff --git a/coip/apps/invitation/models.py b/coip/apps/invitation/models.py index 96a856a..f42ac6a 100644 --- a/coip/apps/invitation/models.py +++ b/coip/apps/invitation/models.py @@ -29,24 +29,23 @@ class Invitation(models.Model): def send_email(self): pinviter = last_used_profile(self.inviter) - send_mail('[coip] Invitation to join \'%s\'' % (self.name.short), + send_mail('[coip] Invitation to join \'%s\'' % (self.name.short), ''' - - %s (%s) has invited you to join \'%s\': - - %s - - If you want to accept the invitation open this link in your browser: - - http://localhost/invitation/%s/accept - - To view information about \'%s\' open this link in your browser: - - http://localhost/name/%s - - ''' % (pinviter.display_name,pinviter.identifier,self.name.short,self.message,self.nonce,self.name.id), - 'noreply@coip.example.com',[self.email], fail_silently=False) +%s (%s) has invited you to join \'%s\': - pprint("sent email to %s" % (self.email)) +--- +%s +--- + +If you want to accept the invitation open this link in your browser: +http://localhost/invitation/%s/accept + +To view information about \'%s\' open this link in your browser: +http://localhost/name/%s + +''' % (pinviter.display_name,pinviter.identifier,self.name.short,self.message,self.nonce,self.name.short,self.name.id), + 'noreply@coip.example.com', + [self.email], + fail_silently=False) return |