Fix API for organizers and events with a . in their slug

This commit is contained in:
Raphael Michel
2020-09-16 16:37:36 +02:00
parent ea5fc3df40
commit 22c6553a48
2 changed files with 2 additions and 0 deletions

View File

@@ -73,6 +73,7 @@ class EventViewSet(viewsets.ModelViewSet):
queryset = Event.objects.none()
lookup_field = 'slug'
lookup_url_kwarg = 'event'
lookup_value_regex = '[^/]+'
permission_classes = (EventCRUDPermission,)
filter_backends = (DjangoFilterBackend, filters.OrderingFilter)
ordering = ('slug',)