mirror of
https://github.com/pretix/pretix.git
synced 2026-05-20 17:44:02 +00:00
Compare commits
8 Commits
release/20
...
dependabot
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
18b2f29cba | ||
|
|
4f9297e7d8 | ||
|
|
70b48fdd4b | ||
|
|
e7b5317431 | ||
|
|
63ef2e70e2 | ||
|
|
c4db2a48b6 | ||
|
|
de255b021e | ||
|
|
d3fce71b7f |
@@ -51,7 +51,7 @@ dependencies = [
|
||||
"django-markup",
|
||||
"django-oauth-toolkit==2.3.*",
|
||||
"django-otp==1.5.*",
|
||||
"django-phonenumber-field==7.3.*",
|
||||
"django-phonenumber-field==8.0.*",
|
||||
"django-redis==5.4.*",
|
||||
"django-scopes==2.0.*",
|
||||
"django-statici18n==2.5.*",
|
||||
|
||||
@@ -19,4 +19,4 @@
|
||||
# You should have received a copy of the GNU Affero General Public License along with this program. If not, see
|
||||
# <https://www.gnu.org/licenses/>.
|
||||
#
|
||||
__version__ = "2024.6.1"
|
||||
__version__ = "2024.7.0.dev0"
|
||||
|
||||
@@ -37,6 +37,7 @@ from decimal import Decimal
|
||||
from zoneinfo import ZoneInfo
|
||||
|
||||
from django import forms
|
||||
from django.conf import settings
|
||||
from django.db.models import (
|
||||
Case, CharField, Count, DateTimeField, F, IntegerField, Max, Min, OuterRef,
|
||||
Q, Subquery, Sum, When,
|
||||
@@ -54,7 +55,7 @@ from openpyxl.comments import Comment
|
||||
from openpyxl.styles import Font, PatternFill
|
||||
|
||||
from pretix.base.models import (
|
||||
GiftCard, GiftCardTransaction, Invoice, InvoiceAddress, Order,
|
||||
Checkin, GiftCard, GiftCardTransaction, Invoice, InvoiceAddress, Order,
|
||||
OrderPosition, Question,
|
||||
)
|
||||
from pretix.base.models.orders import (
|
||||
@@ -541,6 +542,22 @@ class OrderListExporter(MultiSheetListExporter):
|
||||
).order_by()
|
||||
qs = base_qs.annotate(
|
||||
payment_providers=Subquery(p_providers, output_field=CharField()),
|
||||
checked_in_lists=Subquery(
|
||||
Checkin.objects.filter(
|
||||
successful=True,
|
||||
type=Checkin.TYPE_ENTRY,
|
||||
position=OuterRef("pk"),
|
||||
).order_by().values("position").annotate(
|
||||
c=GroupConcat(
|
||||
"list__name",
|
||||
# These appear not to work properly on SQLite. Well, we don't support SQLite outside testing
|
||||
# anyways.
|
||||
ordered='sqlite' not in settings.DATABASES['default']['ENGINE'],
|
||||
distinct='sqlite' not in settings.DATABASES['default']['ENGINE'],
|
||||
delimiter=", "
|
||||
)
|
||||
).values("c")
|
||||
),
|
||||
).select_related(
|
||||
'order', 'order__invoice_address', 'order__customer', 'item', 'variation',
|
||||
'voucher', 'tax_rule'
|
||||
@@ -638,6 +655,7 @@ class OrderListExporter(MultiSheetListExporter):
|
||||
_('Sales channel'), _('Order locale'),
|
||||
_('E-mail address verified'),
|
||||
_('External customer ID'),
|
||||
_('Check-in lists'),
|
||||
_('Payment providers'),
|
||||
]
|
||||
|
||||
@@ -776,6 +794,7 @@ class OrderListExporter(MultiSheetListExporter):
|
||||
_('Yes') if order.email_known_to_work else _('No'),
|
||||
str(order.customer.external_identifier) if order.customer and order.customer.external_identifier else '',
|
||||
]
|
||||
row.append(op.checked_in_lists or "")
|
||||
row.append(', '.join([
|
||||
str(self.providers.get(p, p)) for p in sorted(set((op.payment_providers or '').split(',')))
|
||||
if p and p != 'free'
|
||||
|
||||
@@ -38,7 +38,6 @@ from datetime import datetime
|
||||
from django import forms
|
||||
from django.utils.formats import get_format
|
||||
from django.utils.functional import lazy
|
||||
from django.utils.html import escape
|
||||
from django.utils.timezone import get_current_timezone, now
|
||||
from django.utils.translation import gettext_lazy as _
|
||||
|
||||
@@ -65,7 +64,7 @@ def format_placeholders_help_text(placeholders, event=None):
|
||||
placeholders = [(k, v.render_sample(event) if event else v) for k, v in placeholders.items()]
|
||||
placeholders.sort(key=lambda x: x[0])
|
||||
phs = [
|
||||
'<button type="button" class="content-placeholder" title="%s">{%s}</button>' % (escape(_("Sample: %s") % v) if v else "", escape(k))
|
||||
'<button type="button" class="content-placeholder" title="%s">{%s}</button>' % (_("Sample: %s") % v if v else "", k)
|
||||
for k, v in placeholders
|
||||
]
|
||||
return _('Available placeholders: {list}').format(
|
||||
|
||||
@@ -62,7 +62,6 @@ from django.http import (
|
||||
from django.shortcuts import get_object_or_404, redirect
|
||||
from django.urls import reverse
|
||||
from django.utils.functional import cached_property
|
||||
from django.utils.html import escape
|
||||
from django.utils.http import url_has_allowed_host_and_scheme
|
||||
from django.utils.timezone import now
|
||||
from django.utils.translation import gettext, gettext_lazy as _, gettext_noop
|
||||
@@ -737,7 +736,7 @@ class MailSettingsPreview(EventPermissionRequiredMixin, View):
|
||||
else:
|
||||
ctx[p.identifier] = '<span class="placeholder" title="{}">{}</span>'.format(
|
||||
_('This value will be replaced based on dynamic parameters.'),
|
||||
escape(s)
|
||||
s
|
||||
)
|
||||
return ctx
|
||||
|
||||
@@ -787,7 +786,7 @@ class MailSettingsRendererPreview(MailSettingsPreview):
|
||||
def placeholders(self, item):
|
||||
ctx = {}
|
||||
for p in get_available_placeholders(self.request.event, MailSettingsForm.base_context[item]).values():
|
||||
ctx[p.identifier] = escape(str(p.render_sample(self.request.event)))
|
||||
ctx[p.identifier] = str(p.render_sample(self.request.event))
|
||||
return ctx
|
||||
|
||||
def get(self, request, *args, **kwargs):
|
||||
|
||||
@@ -50,7 +50,7 @@ from django.http import (
|
||||
from django.shortcuts import redirect, render
|
||||
from django.urls import resolve, reverse
|
||||
from django.utils.functional import cached_property
|
||||
from django.utils.html import escape, format_html
|
||||
from django.utils.html import format_html
|
||||
from django.utils.safestring import mark_safe
|
||||
from django.utils.timezone import now
|
||||
from django.utils.translation import gettext_lazy as _
|
||||
@@ -562,7 +562,7 @@ class VoucherBulkMailPreview(EventPermissionRequiredMixin, View):
|
||||
else:
|
||||
ctx[p.identifier] = '<span class="placeholder" title="{}">{}</span>'.format(
|
||||
_('This value will be replaced based on dynamic parameters.'),
|
||||
escape(s)
|
||||
s
|
||||
)
|
||||
return self.SafeDict(ctx)
|
||||
|
||||
|
||||
@@ -64,7 +64,8 @@ def casual_reads():
|
||||
|
||||
class GroupConcat(Aggregate):
|
||||
function = 'group_concat'
|
||||
template = '%(function)s(%(field)s, "%(separator)s")'
|
||||
template = '%(function)s(%(distinct)s%(field)s, "%(separator)s")'
|
||||
allow_distinct = True
|
||||
|
||||
def __init__(self, *expressions, ordered=False, **extra):
|
||||
self.ordered = ordered
|
||||
@@ -73,19 +74,17 @@ class GroupConcat(Aggregate):
|
||||
extra.update({'separator': ','})
|
||||
super().__init__(*expressions, **extra)
|
||||
|
||||
def as_postgresql(self, compiler, connection):
|
||||
def as_postgresql(self, compiler, connection, **extra_context):
|
||||
if self.ordered:
|
||||
return super().as_sql(
|
||||
compiler, connection,
|
||||
function='string_agg',
|
||||
template="%(function)s(%(field)s::text, '%(separator)s' ORDER BY %(field)s ASC)",
|
||||
)
|
||||
template = "%(function)s(%(distinct)s%(field)s::text, '%(separator)s' ORDER BY %(field)s::text ASC)"
|
||||
else:
|
||||
return super().as_sql(
|
||||
compiler, connection,
|
||||
function='string_agg',
|
||||
template="%(function)s(%(field)s::text, '%(separator)s')",
|
||||
)
|
||||
template = "%(function)s(%(distinct)s%(field)s::text, '%(separator)s')"
|
||||
return super().as_sql(
|
||||
compiler, connection,
|
||||
function='string_agg',
|
||||
template=template,
|
||||
**extra_context,
|
||||
)
|
||||
|
||||
|
||||
class ReplicaRouter:
|
||||
|
||||
@@ -8,8 +8,8 @@ msgstr ""
|
||||
"Project-Id-Version: PACKAGE VERSION\n"
|
||||
"Report-Msgid-Bugs-To: \n"
|
||||
"POT-Creation-Date: 2024-06-24 08:20+0000\n"
|
||||
"PO-Revision-Date: 2024-01-31 04:00+0000\n"
|
||||
"Last-Translator: Eduardo Fernandez <sistemas@oyasama.es>\n"
|
||||
"PO-Revision-Date: 2024-06-24 15:12+0000\n"
|
||||
"Last-Translator: Mira <weller@rami.io>\n"
|
||||
"Language-Team: Spanish <https://translate.pretix.eu/projects/pretix/pretix/"
|
||||
"es/>\n"
|
||||
"Language: es\n"
|
||||
@@ -17,7 +17,7 @@ msgstr ""
|
||||
"Content-Type: text/plain; charset=UTF-8\n"
|
||||
"Content-Transfer-Encoding: 8bit\n"
|
||||
"Plural-Forms: nplurals=2; plural=n != 1;\n"
|
||||
"X-Generator: Weblate 5.3.1\n"
|
||||
"X-Generator: Weblate 5.5.5\n"
|
||||
|
||||
#: pretix/_base_settings.py:78
|
||||
msgid "English"
|
||||
@@ -37,7 +37,7 @@ msgstr "Árabe"
|
||||
|
||||
#: pretix/_base_settings.py:82
|
||||
msgid "Catalan"
|
||||
msgstr ""
|
||||
msgstr "catalán"
|
||||
|
||||
#: pretix/_base_settings.py:83
|
||||
msgid "Chinese (simplified)"
|
||||
@@ -117,7 +117,7 @@ msgstr "Ruso"
|
||||
|
||||
#: pretix/_base_settings.py:102
|
||||
msgid "Slovak"
|
||||
msgstr ""
|
||||
msgstr "eslovaco"
|
||||
|
||||
#: pretix/_base_settings.py:103
|
||||
msgid "Spanish"
|
||||
@@ -2876,7 +2876,7 @@ msgstr "Código del cupón"
|
||||
#: pretix/base/forms/__init__.py:118
|
||||
#, python-brace-format
|
||||
msgid "You can use {markup_name} in this field."
|
||||
msgstr ""
|
||||
msgstr "Se puede usar {markup_name} en este campo."
|
||||
|
||||
#: pretix/base/forms/__init__.py:178
|
||||
#, python-format
|
||||
@@ -3095,6 +3095,10 @@ msgid ""
|
||||
"up. Please note: to use literal \"{\" or \"}\", you need to double them as "
|
||||
"\"{{\" and \"}}\"."
|
||||
msgstr ""
|
||||
"Hay un error con el sintaxis de marcador de posición. Por favor, asegúrase "
|
||||
"de que las llaves de apertura «{» y las llaves de cierre «}» de sus "
|
||||
"marcadores de posición coinciden. Tenga en cuenta: para usar «{» o «}» "
|
||||
"literalmente, se debe teclearlas dos veces como «{{» o «}}» respectivamente."
|
||||
|
||||
#: pretix/base/forms/validators.py:72 pretix/control/views/event.py:771
|
||||
#, fuzzy, python-format
|
||||
@@ -4601,7 +4605,7 @@ msgstr "Esperando, producto no disponible"
|
||||
#: pretix/base/models/items.py:382
|
||||
#: pretix/control/templates/pretixcontrol/subevents/fragment_unavail_mode_indicator.html:5
|
||||
msgid "Show info text if unavailable"
|
||||
msgstr ""
|
||||
msgstr "Muestra el texto informativo, si no es disponible"
|
||||
|
||||
#: pretix/base/models/items.py:389 pretix/base/models/items.py:704
|
||||
msgid "Don't use re-usable media, use regular one-off tickets"
|
||||
@@ -5964,6 +5968,9 @@ msgid ""
|
||||
"up two-factor authentication or leave the team. The setting may take a few "
|
||||
"minutes to become effective for all users."
|
||||
msgstr ""
|
||||
"Si activado, todos los miembros del equipo requerirán configurar la "
|
||||
"autenticación de dos factores o dejar el equipo. El ajuste podría tardar "
|
||||
"pocos minutos para activar para todos los usuarios."
|
||||
|
||||
#: pretix/base/models/organizer.py:275
|
||||
msgid "Can create events"
|
||||
@@ -6240,6 +6247,9 @@ msgid ""
|
||||
"of a specific product, you can also select a quota. In this case, all "
|
||||
"products assigned to this quota can be selected."
|
||||
msgstr ""
|
||||
"Este producto añadirá al carrito del usuario si está usado el vale. En vez "
|
||||
"de un producto específico, se puede seleccionar una cuota. En este caso, "
|
||||
"todos los productos que están asignados al esta cuota se pueden seleccionar."
|
||||
|
||||
#: pretix/base/models/vouchers.py:265
|
||||
msgid "This variation of the product select above is being used."
|
||||
@@ -9651,6 +9661,11 @@ msgid ""
|
||||
"still people on the waiting list. Vouchers that have already been sent "
|
||||
"remain active."
|
||||
msgstr ""
|
||||
"La lista de espera estará deshabilitada después de esta fecha. Esto "
|
||||
"significa que nadie puede añadirse a la lista; sin embargo, las entradas "
|
||||
"estarán disponibles para la venta de nuevo si permite la cuota, incluso si "
|
||||
"hay alguien en la lista de espera. Los vales que ya se han enviado "
|
||||
"permanecerán activos."
|
||||
|
||||
#: pretix/base/settings.py:1420
|
||||
msgid "Ask for a name"
|
||||
@@ -9894,7 +9909,7 @@ msgstr "Ocultar todas las fechas pasadas del calendario"
|
||||
|
||||
#: pretix/base/settings.py:1664 pretix/base/settings.py:1673
|
||||
msgid "No modifications after order was submitted"
|
||||
msgstr ""
|
||||
msgstr "Ningunas modificaciones se entregaron después del pedido"
|
||||
|
||||
#: pretix/base/settings.py:1665 pretix/base/settings.py:1674
|
||||
#, fuzzy
|
||||
@@ -9904,7 +9919,7 @@ msgstr "Sólo las órdenes pendientes o pagadas pueden ser cambiadas."
|
||||
|
||||
#: pretix/base/settings.py:1666 pretix/base/settings.py:1675
|
||||
msgid "Both the attendee and the person who ordered can make changes"
|
||||
msgstr ""
|
||||
msgstr "Ambos el/la asistente y el/la comprador(a) pueden hacer cambios"
|
||||
|
||||
#: pretix/base/settings.py:1670
|
||||
#, fuzzy
|
||||
@@ -9923,6 +9938,8 @@ msgid ""
|
||||
"By default, no more modifications are possible for an order as soon as one "
|
||||
"of the tickets in the order has been checked in."
|
||||
msgstr ""
|
||||
"Por defecto, las modificaciones del pedido no se estarán permitidas una vez "
|
||||
"que una de las entradas del pedido se hayan canjeado."
|
||||
|
||||
#: pretix/base/settings.py:1696
|
||||
msgid "Last date of modifications"
|
||||
@@ -16020,6 +16037,8 @@ msgid ""
|
||||
"A first login using {agent_type} on {os_type} from {country} has been "
|
||||
"detected."
|
||||
msgstr ""
|
||||
"Se ha detectado un inicio de sesión nuevo por {agent_type} usando {os_type} "
|
||||
"de {country}."
|
||||
|
||||
#: pretix/control/logdisplay.py:460 pretix/control/views/user.py:489
|
||||
#: pretix/control/views/user.py:549 pretix/control/views/user.py:608
|
||||
@@ -18110,6 +18129,21 @@ msgid ""
|
||||
"Best regards, \n"
|
||||
"Your %(instance)s team\n"
|
||||
msgstr ""
|
||||
"Hola,\n"
|
||||
"\n"
|
||||
"Se ha detectado un inicio de sesión de tu cuenta %(instance)s por una "
|
||||
"ubicación nueva o inusual. Se inició el sesión por %(agent)s de %(os)s de "
|
||||
"%(country)s.\n"
|
||||
"\n"
|
||||
"Si tú hiciste esto, puedes ignorar este correo.\n"
|
||||
"\n"
|
||||
"Si no fuiste tú, recomendamos que cambies la contraseña en los ajustes de "
|
||||
"cuenta:\n"
|
||||
"\n"
|
||||
"%(url)s\n"
|
||||
"\n"
|
||||
"Saludos cordiales,\n"
|
||||
"Su equipo de %(instance)s\n"
|
||||
|
||||
#: pretix/control/templates/pretixcontrol/email/security_notice.txt:1
|
||||
#, python-format
|
||||
@@ -19970,52 +20004,51 @@ msgstr ""
|
||||
|
||||
#: pretix/control/templates/pretixcontrol/global_sysreport.html:16
|
||||
msgid "January"
|
||||
msgstr "Enero"
|
||||
msgstr "enero"
|
||||
|
||||
#: pretix/control/templates/pretixcontrol/global_sysreport.html:17
|
||||
msgid "February"
|
||||
msgstr "Febrero"
|
||||
msgstr "febrero"
|
||||
|
||||
#: pretix/control/templates/pretixcontrol/global_sysreport.html:18
|
||||
#, fuzzy
|
||||
msgid "March"
|
||||
msgstr "Marzo"
|
||||
msgstr "marzo"
|
||||
|
||||
#: pretix/control/templates/pretixcontrol/global_sysreport.html:19
|
||||
msgid "April"
|
||||
msgstr "Abril"
|
||||
msgstr "abril"
|
||||
|
||||
#: pretix/control/templates/pretixcontrol/global_sysreport.html:20
|
||||
msgid "May"
|
||||
msgstr "Mayo"
|
||||
msgstr "mayo"
|
||||
|
||||
#: pretix/control/templates/pretixcontrol/global_sysreport.html:21
|
||||
msgid "June"
|
||||
msgstr "Junio"
|
||||
msgstr "junio"
|
||||
|
||||
#: pretix/control/templates/pretixcontrol/global_sysreport.html:22
|
||||
msgid "July"
|
||||
msgstr "Julio"
|
||||
msgstr "julio"
|
||||
|
||||
#: pretix/control/templates/pretixcontrol/global_sysreport.html:23
|
||||
msgid "August"
|
||||
msgstr "Agosto"
|
||||
msgstr "agosto"
|
||||
|
||||
#: pretix/control/templates/pretixcontrol/global_sysreport.html:24
|
||||
msgid "September"
|
||||
msgstr "Septiembre"
|
||||
msgstr "septiembre"
|
||||
|
||||
#: pretix/control/templates/pretixcontrol/global_sysreport.html:25
|
||||
msgid "October"
|
||||
msgstr "Octubre"
|
||||
msgstr "octubre"
|
||||
|
||||
#: pretix/control/templates/pretixcontrol/global_sysreport.html:26
|
||||
msgid "November"
|
||||
msgstr "Noviembre"
|
||||
msgstr "noviembre"
|
||||
|
||||
#: pretix/control/templates/pretixcontrol/global_sysreport.html:27
|
||||
msgid "December"
|
||||
msgstr "Diciembre"
|
||||
msgstr "diciembre"
|
||||
|
||||
#: pretix/control/templates/pretixcontrol/global_sysreport.html:32
|
||||
#, fuzzy
|
||||
|
||||
@@ -8,16 +8,16 @@ msgstr ""
|
||||
"Project-Id-Version: PACKAGE VERSION\n"
|
||||
"Report-Msgid-Bugs-To: \n"
|
||||
"POT-Creation-Date: 2024-06-24 08:20+0000\n"
|
||||
"PO-Revision-Date: 2023-11-07 14:00+0000\n"
|
||||
"Last-Translator: Zona Vip <contacto@zonavip.mx>\n"
|
||||
"Language-Team: Spanish <https://translate.pretix.eu/projects/pretix/pretix-"
|
||||
"js/es/>\n"
|
||||
"PO-Revision-Date: 2024-06-24 15:12+0000\n"
|
||||
"Last-Translator: Mira <weller@rami.io>\n"
|
||||
"Language-Team: Spanish <https://translate.pretix.eu/projects/pretix/"
|
||||
"pretix-js/es/>\n"
|
||||
"Language: es\n"
|
||||
"MIME-Version: 1.0\n"
|
||||
"Content-Type: text/plain; charset=UTF-8\n"
|
||||
"Content-Transfer-Encoding: 8bit\n"
|
||||
"Plural-Forms: nplurals=2; plural=n != 1;\n"
|
||||
"X-Generator: Weblate 5.1.1\n"
|
||||
"X-Generator: Weblate 5.5.5\n"
|
||||
|
||||
#: pretix/plugins/banktransfer/static/pretixplugins/banktransfer/ui.js:56
|
||||
#: pretix/plugins/banktransfer/static/pretixplugins/banktransfer/ui.js:62
|
||||
@@ -1069,51 +1069,51 @@ msgstr "Dom"
|
||||
|
||||
#: pretix/static/pretixpresale/js/widget/widget.js:78
|
||||
msgid "January"
|
||||
msgstr "Enero"
|
||||
msgstr "enero"
|
||||
|
||||
#: pretix/static/pretixpresale/js/widget/widget.js:79
|
||||
msgid "February"
|
||||
msgstr "Febrero"
|
||||
msgstr "febrero"
|
||||
|
||||
#: pretix/static/pretixpresale/js/widget/widget.js:80
|
||||
msgid "March"
|
||||
msgstr "Marzo"
|
||||
msgstr "marzo"
|
||||
|
||||
#: pretix/static/pretixpresale/js/widget/widget.js:81
|
||||
msgid "April"
|
||||
msgstr "Abril"
|
||||
msgstr "abril"
|
||||
|
||||
#: pretix/static/pretixpresale/js/widget/widget.js:82
|
||||
msgid "May"
|
||||
msgstr "Mayo"
|
||||
msgstr "mayo"
|
||||
|
||||
#: pretix/static/pretixpresale/js/widget/widget.js:83
|
||||
msgid "June"
|
||||
msgstr "Junio"
|
||||
msgstr "junio"
|
||||
|
||||
#: pretix/static/pretixpresale/js/widget/widget.js:84
|
||||
msgid "July"
|
||||
msgstr "Julio"
|
||||
msgstr "julio"
|
||||
|
||||
#: pretix/static/pretixpresale/js/widget/widget.js:85
|
||||
msgid "August"
|
||||
msgstr "Agosto"
|
||||
msgstr "agosto"
|
||||
|
||||
#: pretix/static/pretixpresale/js/widget/widget.js:86
|
||||
msgid "September"
|
||||
msgstr "Septiembre"
|
||||
msgstr "septiembre"
|
||||
|
||||
#: pretix/static/pretixpresale/js/widget/widget.js:87
|
||||
msgid "October"
|
||||
msgstr "Octubre"
|
||||
msgstr "octubre"
|
||||
|
||||
#: pretix/static/pretixpresale/js/widget/widget.js:88
|
||||
msgid "November"
|
||||
msgstr "Noviembre"
|
||||
msgstr "noviembre"
|
||||
|
||||
#: pretix/static/pretixpresale/js/widget/widget.js:89
|
||||
msgid "December"
|
||||
msgstr "Diciembre"
|
||||
msgstr "diciembre"
|
||||
|
||||
#~ msgctxt "widget"
|
||||
#~ msgid "See variations"
|
||||
|
||||
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
@@ -46,7 +46,6 @@ from django.shortcuts import get_object_or_404, redirect
|
||||
from django.template.loader import get_template
|
||||
from django.urls import reverse
|
||||
from django.utils.functional import cached_property
|
||||
from django.utils.html import escape
|
||||
from django.utils.timezone import now
|
||||
from django.utils.translation import gettext_lazy as _, ngettext
|
||||
from django.views.generic import DeleteView, FormView, ListView, TemplateView
|
||||
@@ -194,7 +193,7 @@ class BaseSenderView(EventPermissionRequiredMixin, FormView):
|
||||
for k, v in get_available_placeholders(self.request.event, self.context_parameters).items():
|
||||
context_dict[k] = '<span class="placeholder" title="{}">{}</span>'.format(
|
||||
_('This value will be replaced based on dynamic parameters.'),
|
||||
escape(v.render_sample(self.request.event))
|
||||
v.render_sample(self.request.event)
|
||||
)
|
||||
|
||||
subject = bleach.clean(form.cleaned_data['subject'].localize(l), tags=[])
|
||||
@@ -609,7 +608,7 @@ class CreateRule(EventPermissionRequiredMixin, CreateView):
|
||||
'position_or_address']).items():
|
||||
context_dict[k] = '<span class="placeholder" title="{}">{}</span>'.format(
|
||||
_('This value will be replaced based on dynamic parameters.'),
|
||||
escape(v.render_sample(self.request.event))
|
||||
v.render_sample(self.request.event)
|
||||
)
|
||||
|
||||
subject = bleach.clean(form.cleaned_data['subject'].localize(l), tags=[])
|
||||
@@ -685,7 +684,7 @@ class UpdateRule(EventPermissionRequiredMixin, UpdateView):
|
||||
for k, v in get_available_placeholders(self.request.event, ['event', 'order', 'position_or_address']).items():
|
||||
placeholders[k] = '<span class="placeholder" title="{}">{}</span>'.format(
|
||||
_('This value will be replaced based on dynamic parameters.'),
|
||||
escape(v.render_sample(self.request.event))
|
||||
v.render_sample(self.request.event)
|
||||
)
|
||||
|
||||
subject = bleach.clean(self.object.subject.localize(lang), tags=[])
|
||||
|
||||
Reference in New Issue
Block a user