修复: 全栈审查 FR-C1~C5 五项正确性 bug
- FR-C1 formattedEvents 时间漂移:事件入数组固 _ts 时间戳(project.ts push + ProjectDetail 用 _ts),computed 重算不再刷历史时间为当前时刻 - FR-C2 sentiment 三档统一:模板 >0/<0/===0 + sentimentClass 同源 + i18n neutral(zh/en),原模板>0 与 class>=0 矛盾 - FR-C3 Settings timer 泄漏:onUnmounted 清全部三个(原仅 _concurrencyTimer) - FR-C4 MIGRATION_VERSION 死常量:删(零代码引用,run() if 链自管版本) - FR-C5 AiConversationDetail 缺 readonly:加 readonly?: boolean(后端 generating 时返回) 来源 fullstack-review §3(已核实);cargo/vue-tsc 0 err
This commit is contained in:
@@ -11,7 +11,7 @@ const state = reactive({
|
||||
tasks: [] as TaskRecord[],
|
||||
ideas: [] as IdeaRecord[],
|
||||
workflowExecutions: [] as WorkflowRecord[],
|
||||
liveEvents: [] as WorkflowEventPayload[],
|
||||
liveEvents: [] as Array<WorkflowEventPayload & { _ts: number }>,
|
||||
pendingApproval: null as {
|
||||
execution_id: string
|
||||
node_id: string
|
||||
@@ -209,7 +209,8 @@ function createStore() {
|
||||
if (_eventUnlisten) return _eventUnlisten
|
||||
_eventUnlisten = await workflowApi.onEvent((payload) => {
|
||||
try {
|
||||
state.liveEvents.push(payload)
|
||||
// 固时间戳(FR-C1):formattedEvents computed 重算时用事件发生时刻,非当前时刻
|
||||
state.liveEvents.push({ ...payload, _ts: Date.now() })
|
||||
// 处理人工审批请求
|
||||
// WorkflowEvent serde tag=type rename_all=snake_case → type='human_approval_request',字段扁平(无 data 包装)(B-03b-R7)
|
||||
if (payload.event?.type === 'human_approval_request') {
|
||||
|
||||
Reference in New Issue
Block a user