forked from CGM_Public/pretix_original
Add now_date
This commit is contained in:
@@ -193,6 +193,14 @@ DEFAULT_VARIABLES = OrderedDict((
|
|||||||
"editor_sample": _("Event organizer info text"),
|
"editor_sample": _("Event organizer info text"),
|
||||||
"evaluate": lambda op, order, ev: str(order.event.settings.organizer_info_text)
|
"evaluate": lambda op, order, ev: str(order.event.settings.organizer_info_text)
|
||||||
}),
|
}),
|
||||||
|
("now_date", {
|
||||||
|
"label": _("Printing date"),
|
||||||
|
"editor_sample": _("2017-05-31"),
|
||||||
|
"evaluate": lambda op, order, ev: date_format(
|
||||||
|
now().astimezone(timezone(ev.settings.timezone)),
|
||||||
|
"SHORT_DATE_FORMAT"
|
||||||
|
)
|
||||||
|
}),
|
||||||
("now_datetime", {
|
("now_datetime", {
|
||||||
"label": _("Printing date and time"),
|
"label": _("Printing date and time"),
|
||||||
"editor_sample": _("2017-05-31 19:00"),
|
"editor_sample": _("2017-05-31 19:00"),
|
||||||
|
|||||||
Reference in New Issue
Block a user