feat: 任务可调并发、可批量操作,导航栏可收缩

This commit is contained in:
2026-10-25 08:22:32 +08:00
parent 6a230ee8d4
commit 5f3bb312b3
10 changed files with 375 additions and 56 deletions
+7
View File
@@ -74,6 +74,13 @@ export function pauseJob(id: string) {
return api<DownloadJob>(`/api/download/jobs/${id}/pause`, { method: "POST" });
}
export function updateConcurrency(id: string, concurrency: number) {
return api<DownloadJob>(`/api/download/jobs/${id}/concurrency`, {
method: "PUT",
body: JSON.stringify({ concurrency }),
});
}
export function deleteJob(id: string, files: boolean) {
const flag = files ? "true" : "false";
return api<unknown>(`/api/download/jobs/${encodeURIComponent(id)}?files=${flag}`, { method: "DELETE" });