Merge branch 'dev' into prod

This commit is contained in:
北枳 2025-10-10 22:16:49 +08:00
commit 45f6c86547

View File

@ -552,7 +552,8 @@ export function useWorkflowData({}: UseWorkflowDataProps = {}) {
}); });
// 设置是否需要获取流式数据 // 设置是否需要获取流式数据
setNeedStreamData(taskCurrent.status !== 'COMPLETED'); // setNeedStreamData(taskCurrent.status !== 'COMPLETED');
setNeedStreamData(true);
} catch (error) { } catch (error) {
console.error('初始化失败:', error); console.error('初始化失败:', error);
@ -578,6 +579,8 @@ export function useWorkflowData({}: UseWorkflowDataProps = {}) {
}); });
// 重置视频状态为生成中 // 重置视频状态为生成中
await new Promise(resolve => { await new Promise(resolve => {
const { current: taskCurrent } = tempTaskObject;
taskCurrent.videos.data.find((v: any) => v.video_id === video_id)!.video_status = 0;
setTaskObject(prev => { setTaskObject(prev => {
const newState = JSON.parse(JSON.stringify(prev)); const newState = JSON.parse(JSON.stringify(prev));
const videoIndex = newState.videos.data.findIndex((v: any) => v.video_id === video_id); const videoIndex = newState.videos.data.findIndex((v: any) => v.video_id === video_id);