Esempio n. 1
0
 def make_email(self, notification):
     return EmailTemplate._apply_top_template(
         notification.notifier,
         self.subject,
         self.body.format(link=settings.APP_LINK_RESOLVER(
             notification.reference), ),
         self.html.format(link=settings.APP_LINK_RESOLVER(
             notification.reference), ),
     )
Esempio n. 2
0
 def make_email(self, notification, deposit):
     return EmailTemplate._apply_top_template(
         notification.notifier,
         self.subject,
         self.body.format(
             amount='${:.2f}'.format(deposit.amount / 100),
             link=settings.APP_LINK_RESOLVER(notification.reference),
         ),
         self.html.format(
             amount='${:.2f}'.format(deposit.amount / 100),
             link=settings.APP_LINK_RESOLVER(notification.reference),
         ),
     )
Esempio n. 3
0
 def make_email(self, notification, entry):
     return EmailTemplate._apply_top_template(
         notification.notifier,
         self.subject,
         self.body.format(
             entry_type=get_submodel(
                 entry,
                 ibis.models.Entry,
             ).__name__.lower(),
             link=settings.APP_LINK_RESOLVER(notification.reference),
         ),
         self.html.format(
             entry_type=get_submodel(
                 entry,
                 ibis.models.Entry,
             ).__name__.lower(),
             link=settings.APP_LINK_RESOLVER(notification.reference),
         ),
     )