Sort newest members by start date

This commit is contained in:
Tanner Collin 2023-08-17 22:17:41 +00:00
parent e1e98da7d8
commit 543249335f

View File

@ -99,9 +99,9 @@ class SearchViewSet(Base, Retrieve):
queryset = queryset.order_by('-vetted_date', '-id') queryset = queryset.order_by('-vetted_date', '-id')
elif sort == 'newest_active': elif sort == 'newest_active':
queryset = queryset.filter(paused_date__isnull=True) queryset = queryset.filter(paused_date__isnull=True)
queryset = queryset.order_by('-application_date', '-id') queryset = queryset.order_by('-current_start_date', '-id')
elif sort == 'newest_overall': elif sort == 'newest_overall':
queryset = queryset.order_by('-application_date', '-id') queryset = queryset.order_by('-current_start_date', '-id')
elif sort == 'oldest_active': elif sort == 'oldest_active':
queryset = queryset.filter(paused_date__isnull=True) queryset = queryset.filter(paused_date__isnull=True)
queryset = queryset.order_by('application_date', 'id') queryset = queryset.order_by('application_date', 'id')