默认是已完成状态

This commit is contained in:
海龙 2025-08-10 19:37:49 +08:00
parent 360332efbf
commit 4fccce896e

View File

@ -136,15 +136,15 @@ export class VideoSegmentEntityAdapter {
videoUrls.push(...result.videos.map(video => video.video_url)); videoUrls.push(...result.videos.map(video => video.video_url));
} }
// 根据task_status确定状态 // // 根据task_status确定状态
let status: 0 | 1 | 2 = 1; // 默认为已完成状态 let status: 0 | 1 | 2 = 1; // 默认为已完成状态
if (data.task_status === "INIT" || data.task_status === "IN_PROGRESS") { // if (data.task_status === "INIT" || data.task_status === "IN_PROGRESS") {
status = 0; // 视频加载中INIT和IN_PROGRESS都当成进行中 // status = 0; // 视频加载中INIT和IN_PROGRESS都当成进行中
} else if (data.task_status === "COMPLETED") { // } else if (data.task_status === "COMPLETED") {
status = 1; // 任务已完成 // status = 1; // 任务已完成
} else if (data.task_status === "FAILED") { // } else if (data.task_status === "FAILED") {
status = 2; // 任务失败 // status = 2; // 任务失败
} // }
// 创建VideoSegmentEntity // 创建VideoSegmentEntity
const entity: VideoSegmentEntity = { const entity: VideoSegmentEntity = {