mirror of
https://github.com/pretix/pretix.git
synced 2026-08-22 12:42:00 +00:00
Fix static instance name in emails (Z#23224360) (#5914)
This commit is contained in:
@@ -365,9 +365,10 @@ class TeamInviteSerializer(serializers.ModelSerializer):
|
|||||||
def _send_invite(self, instance):
|
def _send_invite(self, instance):
|
||||||
mail(
|
mail(
|
||||||
instance.email,
|
instance.email,
|
||||||
_('pretix account invitation'),
|
_('Account invitation'),
|
||||||
'pretixcontrol/email/invitation.txt',
|
'pretixcontrol/email/invitation.txt',
|
||||||
{
|
{
|
||||||
|
'instance': settings.PRETIX_INSTANCE_NAME,
|
||||||
'user': self,
|
'user': self,
|
||||||
'organizer': self.context['organizer'].name,
|
'organizer': self.context['organizer'].name,
|
||||||
'team': instance.team.name,
|
'team': instance.team.name,
|
||||||
|
|||||||
@@ -346,7 +346,8 @@ class User(AbstractBaseUser, PermissionsMixin, LoggingMixin):
|
|||||||
{
|
{
|
||||||
'user': self,
|
'user': self,
|
||||||
'messages': msg,
|
'messages': msg,
|
||||||
'url': build_absolute_uri('control:user.settings')
|
'url': build_absolute_uri('control:user.settings'),
|
||||||
|
'instance': settings.PRETIX_INSTANCE_NAME,
|
||||||
},
|
},
|
||||||
event=None,
|
event=None,
|
||||||
user=self,
|
user=self,
|
||||||
@@ -391,6 +392,7 @@ class User(AbstractBaseUser, PermissionsMixin, LoggingMixin):
|
|||||||
'user': self,
|
'user': self,
|
||||||
'reason': msg,
|
'reason': msg,
|
||||||
'code': code,
|
'code': code,
|
||||||
|
'instance': settings.PRETIX_INSTANCE_NAME,
|
||||||
},
|
},
|
||||||
event=None,
|
event=None,
|
||||||
user=self,
|
user=self,
|
||||||
@@ -430,6 +432,7 @@ class User(AbstractBaseUser, PermissionsMixin, LoggingMixin):
|
|||||||
mail(
|
mail(
|
||||||
self.email, _('Password recovery'), 'pretixcontrol/email/forgot.txt',
|
self.email, _('Password recovery'), 'pretixcontrol/email/forgot.txt',
|
||||||
{
|
{
|
||||||
|
'instance': settings.PRETIX_INSTANCE_NAME,
|
||||||
'user': self,
|
'user': self,
|
||||||
'url': (build_absolute_uri('control:auth.forgot.recover')
|
'url': (build_absolute_uri('control:auth.forgot.recover')
|
||||||
+ '?id=%d&token=%s' % (self.id, default_token_generator.make_token(self)))
|
+ '?id=%d&token=%s' % (self.id, default_token_generator.make_token(self)))
|
||||||
|
|||||||
@@ -176,6 +176,7 @@ def shred(self, event: Event, fileid: str, confirm_code: str, user: int=None, lo
|
|||||||
_('Data shredding completed'),
|
_('Data shredding completed'),
|
||||||
'pretixbase/email/shred_completed.txt',
|
'pretixbase/email/shred_completed.txt',
|
||||||
{
|
{
|
||||||
|
'instance': settings.PRETIX_INSTANCE_NAME,
|
||||||
'user': user,
|
'user': user,
|
||||||
'organizer': event.organizer.name,
|
'organizer': event.organizer.name,
|
||||||
'event': str(event.name),
|
'event': str(event.name),
|
||||||
|
|||||||
@@ -13,5 +13,5 @@ Start time: {{ start_time }} (new data added after this time might not have been
|
|||||||
|
|
||||||
Best regards,
|
Best regards,
|
||||||
|
|
||||||
Your pretix team
|
Your {{ instance }} team
|
||||||
{% endblocktrans %}
|
{% endblocktrans %}
|
||||||
|
|||||||
@@ -9,5 +9,5 @@ Please do never give this code to another person. Our support team will never as
|
|||||||
If this code was not requested by you, please contact us immediately.
|
If this code was not requested by you, please contact us immediately.
|
||||||
|
|
||||||
Best regards,
|
Best regards,
|
||||||
Your pretix team
|
Your {{ instance }} team
|
||||||
{% endblocktrans %}
|
{% endblocktrans %}
|
||||||
|
|||||||
@@ -5,5 +5,5 @@ you requested a new password. Please go to the following page to reset your pass
|
|||||||
{{ url }}
|
{{ url }}
|
||||||
|
|
||||||
Best regards,
|
Best regards,
|
||||||
Your pretix team
|
Your {{ instance }} team
|
||||||
{% endblocktrans %}
|
{% endblocktrans %}
|
||||||
|
|||||||
@@ -1,6 +1,6 @@
|
|||||||
{% load i18n %}{% blocktrans with url=url|safe %}Hello,
|
{% load i18n %}{% blocktrans with url=url|safe %}Hello,
|
||||||
|
|
||||||
you have been invited to a team on pretix, a platform to perform event
|
you have been invited to a team on {{ instance }}, a platform to perform event
|
||||||
ticket sales.
|
ticket sales.
|
||||||
|
|
||||||
Organizer: {{ organizer }}
|
Organizer: {{ organizer }}
|
||||||
@@ -13,5 +13,5 @@ If you do not want to join, you can safely ignore or delete this email.
|
|||||||
|
|
||||||
Best regards,
|
Best regards,
|
||||||
|
|
||||||
Your pretix team
|
Your {{ instance }} team
|
||||||
{% endblocktrans %}
|
{% endblocktrans %}
|
||||||
|
|||||||
@@ -1,6 +1,6 @@
|
|||||||
{% load i18n %}{% blocktrans with url=url|safe messages=messages|safe %}Hello,
|
{% load i18n %}{% blocktrans with url=url|safe messages=messages|safe %}Hello,
|
||||||
|
|
||||||
this is to inform you that the account information of your pretix account has been
|
this is to inform you that the account information of your {{ instance }} account has been
|
||||||
changed. In particular, the following changes have been performed:
|
changed. In particular, the following changes have been performed:
|
||||||
|
|
||||||
{{ messages }}
|
{{ messages }}
|
||||||
@@ -12,5 +12,5 @@ You can review and change your account settings here:
|
|||||||
{{ url }}
|
{{ url }}
|
||||||
|
|
||||||
Best regards,
|
Best regards,
|
||||||
Your pretix team
|
Your {{ instance }} team
|
||||||
{% endblocktrans %}
|
{% endblocktrans %}
|
||||||
|
|||||||
@@ -1039,9 +1039,10 @@ class TeamMemberView(OrganizerDetailViewMixin, OrganizerPermissionRequiredMixin,
|
|||||||
def _send_invite(self, instance):
|
def _send_invite(self, instance):
|
||||||
mail(
|
mail(
|
||||||
instance.email,
|
instance.email,
|
||||||
_('pretix account invitation'),
|
_('Account invitation'),
|
||||||
'pretixcontrol/email/invitation.txt',
|
'pretixcontrol/email/invitation.txt',
|
||||||
{
|
{
|
||||||
|
'instance': settings.PRETIX_INSTANCE_NAME,
|
||||||
'user': self,
|
'user': self,
|
||||||
'organizer': self.request.organizer.name,
|
'organizer': self.request.organizer.name,
|
||||||
'team': instance.team.name,
|
'team': instance.team.name,
|
||||||
|
|||||||
Reference in New Issue
Block a user