Answer the question
In order to leave comments, you need to log in
Add your object to the request?
There is an API like this:
class SomeList(ListAPIView):
serializer_class = SomeListSerializer
paginate_by = 5
def get_queryset(self):
return SomeModel.objects.filter(somefilter).order_by('-date')
Answer the question
In order to leave comments, you need to log in
as an option - you can override get_context_data and conjure there, carefully making a list from the QuerySet first
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question