sort download queue autostart on top

This commit is contained in:
Simon
2025-01-30 20:40:43 +07:00
parent 2a331f855c
commit 43bd5359ba

View File

@@ -20,7 +20,14 @@ class DownloadApiListView(ApiBaseView):
def get(self, request):
"""get request"""
query_filter = request.GET.get("filter", False)
self.data.update({"sort": [{"timestamp": {"order": "asc"}}]})
self.data.update(
{
"sort": [
{"auto_start": {"order": "desc"}},
{"timestamp": {"order": "asc"}},
],
}
)
must_list = []
if query_filter: