hit-cxf
2026-04-05 3abc547ccca33690ab063a6cc6b3a00bb8a0f94a
aigc-director/aigc-claw/frontend/components/WorkflowPanel.tsx
@@ -378,6 +378,11 @@
            artifact = artResult.artifact;
          } catch { /* ignore */ }
          // 如果是后处理阶段,即使 artifact 为空也尝试从事件中读取预览数据
          if (stageId === 'post_production' && !artifact && event.data?.assets_preview) {
            artifact = event.data.assets_preview;
          }
          updateStageState(stageId, {
            status: newStatus,
            progress: 100,
@@ -1180,6 +1185,11 @@
      ? stageStates['reference_generation']?.artifact
      : undefined;
    // 传递第1阶段的 artifact 到第4、5、6阶段用于获取剧集标题
    const scriptArtifact = (activeStage === 'reference_generation' || activeStage === 'video_generation' || activeStage === 'post_production')
      ? stageStates['script_generation']?.artifact
      : undefined;
    return (
      <Component
        state={state}
@@ -1200,6 +1210,11 @@
          if (params.videoShotType !== undefined) setVideoShotType(params.videoShotType);
        }}
        referenceArtifact={referenceArtifact}
        scriptArtifact={scriptArtifact}
        artifacts={Object.keys(stageStates).reduce((acc: any, key) => {
          acc[key] = stageStates[key].artifact;
          return acc;
        }, {})}
      />
    );
  };