Add eMail-Template for free approval orders (#1750)

Co-authored-by: Felix Rindt <felix@rindt.me>
This commit is contained in:
Martin Gross
2020-08-13 14:24:39 +02:00
committed by GitHub
parent a2414081af
commit 89a82d75a9
4 changed files with 23 additions and 2 deletions

View File

@@ -258,7 +258,7 @@ def approve_order(order, user=None, send_mail: bool=True, auth=None, force=False
if send_mail:
with language(order.locale):
if order.total == Decimal('0.00'):
email_template = order.event.settings.mail_text_order_free
email_template = order.event.settings.mail_text_order_approved_free
email_subject = _('Order approved and confirmed: %(code)s') % {'code': order.code}
else:
email_template = order.event.settings.mail_text_order_approved

View File

@@ -1419,6 +1419,19 @@ You can select a payment method and perform the payment here:
{url}
Best regards,
Your {event} team"""))
},
'mail_text_order_approved_free': {
'type': LazyI18nString,
'default': LazyI18nString.from_gettext(gettext_noop("""Hello,
we approved your order for {event} and will be happy to welcome you
at our event. As you only ordered free products, no payment is required.
You can change your order details and view the status of your order at
{url}
Best regards,
Your {event} team"""))
},