Commit 1690117f authored by Sébastiaan Versteeg's avatar Sébastiaan Versteeg Committed by Luuk Scholten

Merge branch 'fix/api-display-correct-members-event-registration' into 'master'

Fixed which registrations are retrieved for events

See merge request !509
parent a4cab915
......@@ -78,7 +78,7 @@ class EventViewset(viewsets.ReadOnlyModelViewSet):
event=pk, date_cancelled__not=None)
elif status == 'registered':
queryset = Registration.objects.filter(
event=pk, date_cancelled=None)[event.max_participants:]
event=pk, date_cancelled=None)[:event.max_participants]
serializer = RegistrationSerializer(queryset, many=True,
context={'request': request})
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment