izimobil/django-rest-framework-datatables

How do I get sort and filters to work in override def list(self, request)?

miles-pudge-halter opened this issue · 2 comments

I need custom logic in my ViewSet list method, and the sort does not work. Can someone help me with that please?

Filtering and ordering is done in the filter_queryset method of the filter backend. Maybe you are missing a call to that method? For reference, here is the portion of Django Rest Framework where the filter_queryset call is made in the list method.

Thank you. Didn't fully understand drf viewsets. Totally my bad for creating an issue. I'll close it now.