diff --git a/src/documents/views.py b/src/documents/views.py index bab20230d..08164a91f 100644 --- a/src/documents/views.py +++ b/src/documents/views.py @@ -2233,7 +2233,7 @@ class TasksViewSet(ReadOnlyModelViewSet): filterset_class = PaperlessTaskFilterSet def get_queryset(self): - queryset = PaperlessTask.objects.all().order_by("date_created").reverse() + queryset = PaperlessTask.objects.all().order_by("-date_created") task_id = self.request.query_params.get("task_id") if task_id is not None: queryset = PaperlessTask.objects.filter(task_id=task_id)