forked from CGM_Public/pretix_original
Add region setting to supplement localization (#1875)
This commit is contained in:
@@ -52,7 +52,7 @@ def send_mails(event: Event, user: int, subject: dict, message: dict, orders: li
|
||||
continue
|
||||
|
||||
try:
|
||||
with language(o.locale):
|
||||
with language(o.locale, event.settings.region):
|
||||
email_context = get_email_context(event=event, order=o, position_or_address=p, position=p)
|
||||
mail(
|
||||
p.attendee_email,
|
||||
@@ -80,7 +80,7 @@ def send_mails(event: Event, user: int, subject: dict, message: dict, orders: li
|
||||
|
||||
if send_to_order and o.email:
|
||||
try:
|
||||
with language(o.locale):
|
||||
with language(o.locale, event.settings.region):
|
||||
email_context = get_email_context(event=event, order=o, position_or_address=ia)
|
||||
mail(
|
||||
o.email,
|
||||
|
||||
@@ -127,7 +127,7 @@ class SenderView(EventPermissionRequiredMixin, FormView):
|
||||
|
||||
if self.request.POST.get("action") == "preview":
|
||||
for l in self.request.event.settings.locales:
|
||||
with language(l):
|
||||
with language(l, self.request.event.settings.region):
|
||||
context_dict = TolerantDict()
|
||||
for k, v in get_available_placeholders(self.request.event, ['event', 'order',
|
||||
'position_or_address']).items():
|
||||
|
||||
Reference in New Issue
Block a user