fix organize path mapping and task flow

This commit is contained in:
ShukeBta
2026-06-13 16:32:06 +08:00
parent 9070b4827c
commit 4e0929bbca
23 changed files with 1468 additions and 134 deletions
+22
View File
@@ -8,9 +8,31 @@ export interface ActiveTranscode {
playlist_ok: boolean
}
export interface BackgroundTask {
id: string
kind: string
name: string
status: 'running' | 'completed' | 'failed'
stage?: string
source_path?: string
dest_path?: string
message?: string
error?: string
metrics?: Record<string, number>
started_at: string
updated_at: string
finished_at?: string
}
export interface BackgroundTaskSnapshot {
active: BackgroundTask[]
recent: BackgroundTask[]
}
export interface TasksSnapshot {
transcodes: ActiveTranscode[]
torrents: QBitTorrent[] | null
background_tasks?: BackgroundTaskSnapshot
}
export const tasksAPI = {