From 3f9f2aab2420304b53f32b2978125cb658d4d126 Mon Sep 17 00:00:00 2001 From: GouJ Date: Fri, 25 Sep 2026 00:47:29 +0800 Subject: [PATCH] =?UTF-8?q?fix:=20=E5=88=86=E9=95=9C=E5=8D=95=E9=95=9C?= =?UTF-8?q?=E5=A4=B4=E5=B7=A5=E5=85=B7=E4=B8=8D=E5=8F=97=E5=85=B6=E4=BB=96?= =?UTF-8?q?=E6=93=8D=E4=BD=9C=E9=98=BB=E5=A1=9E?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/features/storyboard/components/ShotTools.vue | 13 ++++++++----- 1 file changed, 8 insertions(+), 5 deletions(-) diff --git a/src/features/storyboard/components/ShotTools.vue b/src/features/storyboard/components/ShotTools.vue index 41c1d7d..c5a19fa 100644 --- a/src/features/storyboard/components/ShotTools.vue +++ b/src/features/storyboard/components/ShotTools.vue @@ -9,7 +9,7 @@ import type { DesignedShot, ShotReferences } from '../types' import type { ShotGenerationSpec } from '../generation-spec.types' import { errorMessage } from '../../../lib/http' import { downloadText } from '../../../lib/format' -import { getOperation, runOperation } from '../../workflows/operations' +import { runOperation } from '../../workflows/operations' import ConfirmAction from '../../workflows/ConfirmAction.vue' /** 镜头级只读资源与显式 Prompt 生成;查询与耗费模型的操作分开。 */ @@ -20,8 +20,7 @@ const errors = ref({ references: '', spec: '' }) const busy = ref({ references: false, spec: false }) const force = ref(false) const prompt = computed(() => getStoryboardSession(props.projectId).prompts[props.shot.shotId]) -const operation = computed(() => getOperation(props.projectId)) -const locked = computed(() => props.disabled || operation.value.pending) +const locked = computed(() => props.disabled) const controllers: Partial> = {} let revision = 0 @@ -88,8 +87,12 @@ async function generatePrompt() { throw new Error('接口未返回此镜头的有效提示词,请检查后端记录后重试。') session.prompts[shotId] = result }) - if (!ok && /primary keyframe|主首帧/i.test(operation.value.error)) { - operation.value.recovery = { + if (!ok) { + // 单镜头错误由 runOperation 记录到项目操作状态;这里只处理可恢复的首帧前置问题。 + const { getOperation } = await import('../../workflows/operations') + const operation = getOperation(projectId) + if (!/primary keyframe|主首帧/i.test(operation.error)) return + operation.recovery = { target: 'keyframe', shotId, episodeNo: props.episodeNo