diff --git a/src/features/breakdown/BreakdownPage.vue b/src/features/breakdown/BreakdownPage.vue index 46eeb4c..f2bbc5b 100644 --- a/src/features/breakdown/BreakdownPage.vue +++ b/src/features/breakdown/BreakdownPage.vue @@ -52,6 +52,13 @@ const backgroundExecution = useWorkflowExecution(projectId, 'breakdown') const recovery = computed(() => recoveryOptions(checkpoints.value)) const execution = computed(() => snapshot.value?.workflowExecution) const taskStopped = computed(() => execution.value?.status === 'failed' || execution.value?.status === 'completed') +/** 后台拆解结束后自动刷新项目、Checkpoint 与正式主体/分镜数据。 */ +watch( + () => backgroundExecution.query.data.value?.status, + (status, previous) => { + if ((status === 'completed' || status === 'failed') && status !== previous) void refresh() + } +) const showRecovery = computed( () => records.value.length > 0 && (execution.value?.status !== 'completed' || validation.value?.valid === false) )