Enable filtering and sorting on all API views

This commit is contained in:
icovada
2026-01-08 21:33:33 +00:00
parent ffa4644e1b
commit 7687ff81c3
6 changed files with 183 additions and 20 deletions
+4
View File
@@ -433,6 +433,10 @@ REST_FRAMEWORK = {
"apps.api.permissions.NotInDemoMode",
"rest_framework.permissions.DjangoModelPermissions",
],
'DEFAULT_FILTER_BACKENDS': [
'django_filters.rest_framework.DjangoFilterBackend',
'rest_framework.filters.OrderingFilter',
],
"DEFAULT_PAGINATION_CLASS": "rest_framework.pagination.PageNumberPagination",
"PAGE_SIZE": 10,
"DEFAULT_SCHEMA_CLASS": "drf_spectacular.openapi.AutoSchema",