mirror of
https://github.com/pretix/pretix.git
synced 2026-05-08 15:44:02 +00:00
Allow to add declaration of accessibility (#5140)
* Allow to add declaration of accessibility * add fallback for empty accessibility_title * unify label format (not "Title for") * move title to top and set helptext before text --------- Co-authored-by: Richard Schreiber <schreiber@rami.io>
This commit is contained in:
@@ -1311,3 +1311,14 @@ class OrganizerFavicon(View):
|
||||
class RedirectToOrganizerIndex(View):
|
||||
def get(self, *args, **kwargs):
|
||||
return redirect_to_url(build_absolute_uri(self.request.organizer, "presale:organizer.index"))
|
||||
|
||||
|
||||
class AccessibilityView(OrganizerViewMixin, EventListMixin, TemplateView):
|
||||
template_name = 'pretixpresale/organizers/accessibility.html'
|
||||
|
||||
def dispatch(self, request, *args, **kwargs):
|
||||
if self.request.organizer.settings.accessibility_url:
|
||||
raise Http404()
|
||||
if not self.request.organizer.settings.accessibility_text:
|
||||
raise Http404()
|
||||
return super().dispatch(request, *args, **kwargs)
|
||||
|
||||
Reference in New Issue
Block a user