feat(short-drama-agent-front): 接入审核人工确认与延期验证
This commit is contained in:
1 parent
5836b90934
commit
c6ef595a8e
23 files changed
+3923
-67
No files matched your search
@@ -25,13 +25,22 @@ const props = withDefaults(
|
||||
showStatusHint?: boolean
|
||||
/** 嵌入弹窗时使用扁平正文,标题、关闭及刷新操作由外层统一提供。 */
|
||||
embedded?: boolean
|
||||
/** 当前项目结果已更新时,旧创作任务只作为历史执行记录展示。 */
|
||||
resultIsHistorical?: boolean
|
||||
}>(),
|
||||
{ title: '制作任务', showStatusHint: true, embedded: false }
|
||||
{ title: '制作任务', showStatusHint: true, embedded: false, resultIsHistorical: false }
|
||||
)
|
||||
/** 刷新状态与隐藏任务记录事件。 */
|
||||
const emit = defineEmits<{ refresh: []; dismiss: [] }>()
|
||||
const percentage = computed(() => executionPercentage(props.execution?.current ?? 0, props.execution?.total ?? 0))
|
||||
const result = computed(() => props.execution?.result ?? {})
|
||||
/** 只改变旧记录的展示语义,不改写原始任务或审核结果。 */
|
||||
const historical = computed(
|
||||
() =>
|
||||
props.resultIsHistorical &&
|
||||
props.execution?.workflowName === 'create-drama' &&
|
||||
['completed', 'failed'].includes(props.execution.status)
|
||||
)
|
||||
/** 动作诊断执行结束仅表示分析完成,不能套用素材生成的通过文案。 */
|
||||
const diagnosisTask = computed(() => props.execution?.workflowName === 'storyboard-legacy-action-diagnosis')
|
||||
/** 服务中断后必须由用户核对记录和费用,不根据未匹配数量自动重试。 */
|
||||
@@ -85,6 +94,7 @@ const progressLabel = computed(() =>
|
||||
const statusLabel = computed(() => {
|
||||
const labels = { pending: '等待开始', running: '执行中', completed: '已完成', failed: '失败' }
|
||||
if (!props.execution) return ''
|
||||
if (historical.value) return '历史执行记录'
|
||||
if (scriptCreation.value && props.execution.status === 'completed') {
|
||||
if (result.value.projectStatus === 'need_review') return '执行结束 · 待修订'
|
||||
if (result.value.projectStatus !== 'completed') return '执行结束 · 结果待确认'
|
||||
@@ -111,6 +121,7 @@ const staleMotionPlanCount = computed(() => {
|
||||
})
|
||||
/** 业务未通过或结果未知时,不把任务执行结束展示为全成功。 */
|
||||
const statusType = computed(() => {
|
||||
if (historical.value) return 'default'
|
||||
if (scriptCreation.value && props.execution?.status === 'completed')
|
||||
return result.value.projectStatus === 'completed'
|
||||
? 'success'
|
||||
@@ -332,7 +343,7 @@ function isInputMode(value: unknown, inputMode: string): boolean {
|
||||
}}可以离开或刷新页面,返回后会继续显示本次任务进度,请勿重复提交。
|
||||
</ContextNotice>
|
||||
<ContextNotice
|
||||
v-else-if="execution.status === 'completed' && showStatusHint"
|
||||
v-else-if="execution.status === 'completed' && showStatusHint && !historical"
|
||||
:type="
|
||||
scriptCreation
|
||||
? result.projectStatus === 'completed'
|
||||
@@ -421,7 +432,7 @@ function isInputMode(value: unknown, inputMode: string): boolean {
|
||||
</p>
|
||||
</ContextNotice>
|
||||
<ContextNotice
|
||||
v-else-if="execution.status === 'failed' && showStatusHint"
|
||||
v-else-if="execution.status === 'failed' && showStatusHint && !historical"
|
||||
type="error"
|
||||
:show-icon="embedded"
|
||||
:emphasized="embedded"
|
||||
|
||||
Reference in new issue
Block a user