优化 strm 同步记录:支持删除记录并展示上传数量统计

This commit is contained in:
truewhile
2026-08-27 10:02:55 +08:00
parent 65c5f3e4bf
commit fc6e2e6f10
7 changed files with 138 additions and 5 deletions
+7
View File
@@ -117,6 +117,13 @@ export const strmAPI = {
.get<StrmSyncRecord[]>('/admin/strm/records', { params: pathId ? { path_id: pathId } : {} })
.then((r) => r.data),
deleteRecord: (id: string) => api.delete(`/admin/strm/records/${id}`).then((r) => r.data),
clearRecords: (pathId?: string) =>
api
.delete<{ deleted: number }>('/admin/strm/records', { params: pathId ? { path_id: pathId } : {} })
.then((r) => r.data),
// ── 本地目录浏览(同步目录选择器) ────────────────────────
listLocalDirs: (path?: string) =>
api