Widget: Show date and time of subevent after calendar selection

This commit is contained in:
Raphael Michel
2020-03-25 17:48:24 +01:00
parent ac3e00fa03
commit 61a1368ed2
3 changed files with 14 additions and 0 deletions

View File

@@ -491,6 +491,11 @@ class WidgetAPIProductList(EventListMixin, View):
ev = self.subevent or request.event
data['name'] = str(ev.name)
data['date_range'] = ev.get_date_range_display() + (
" " + date_format(
ev.date_from.astimezone(request.event.timezone), "TIME_FORMAT"
) if request.event.settings.show_times else ""
)
fail = False
if not ev.presale_is_running: