From 7c969955ae2f2ed61fa3fc620c97d3be29694ec8 Mon Sep 17 00:00:00 2001 From: chenxing Date: Mon, 19 Oct 2026 22:30:05 +0800 Subject: [PATCH] =?UTF-8?q?[fix]=20=E9=80=9A=E7=9F=A5=E8=AF=A6=E6=83=85?= =?UTF-8?q?=E3=80=8C=E5=AE=A1=E6=89=B9=E8=BF=9B=E5=BA=A6=E3=80=8D=E5=8D=A1?= =?UTF-8?q?=E7=89=87=E6=94=B6=E5=8F=A3=EF=BC=9A=E5=85=A8=E9=87=8F=E6=B5=81?= =?UTF-8?q?=E6=B0=B4=E4=BA=A4=E7=BB=99=E3=80=8C=E5=85=A8=E9=83=A8=E5=AE=A1?= =?UTF-8?q?=E6=89=B9=E8=AE=B0=E5=BD=95=E3=80=8D=E6=8A=BD=E5=B1=89?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit - 卡片只留 状态/流程摘要/当前节点/办理意见 + 入口,删掉 steps 时间线与 trace 兜底两段(与下方动作卡 的『最近轨迹』和抽屉三视图三处重复) - 当前节点由 node id 串经 steps.nodeId→nodeName 翻译(此前直接显示 u1 这类 id) - 卡头『审批进度』按钮与抽屉标题统一为『全部审批记录』 - types.ts TraceStep 补 nodeId?(可选字段,向后兼容) --- src/components/flow-approval/types.ts | 2 + src/views/notice/NoticeDetails.vue | 97 +++++++-------------------- 2 files changed, 26 insertions(+), 73 deletions(-) diff --git a/src/components/flow-approval/types.ts b/src/components/flow-approval/types.ts index f9ba9d7..4133b75 100644 --- a/src/components/flow-approval/types.ts +++ b/src/components/flow-approval/types.ts @@ -77,6 +77,8 @@ export interface ByBizResult { /** 审批轨迹(各子应用自有进度接口形态;组件只用其中"最近一步"做摘要,缺位则不展示) */ export interface TraceStep { + /** 节点 id(与 currentNodes 同一口径,用于把 id 串翻成节点名) */ + nodeId?: string | null; nodeName?: string | null; label?: string | null; assignees?: Array<{ userName?: string | null; statusLabel?: string | null; opinion?: string | null }> | null; diff --git a/src/views/notice/NoticeDetails.vue b/src/views/notice/NoticeDetails.vue index ffe2feb..1c20308 100644 --- a/src/views/notice/NoticeDetails.vue +++ b/src/views/notice/NoticeDetails.vue @@ -40,6 +40,23 @@ async function loadTrace() { } } +/** + * 当前节点:flow-center 的 currentNodes 是**节点 id 逗号串**(办件原文口径), + * 用人看的名字得拿 steps 的 nodeId→nodeName 翻;翻不到(老实例/步骤缺失)才回落原 id。 + */ +const currentNodeText = computed(() => { + const ids = String(flowTrace.value?.currentNodes || "") + .split(",") + .map((s) => s.trim()) + .filter(Boolean); + if (!ids.length) return ""; + const names = new Map(); + for (const s of flowTrace.value?.steps || []) { + if (s.nodeId && s.nodeName) names.set(String(s.nodeId), s.nodeName); + } + return ids.map((id) => names.get(id) || id).join("、"); +}); + /** * 撤回:走本应用后端(2026-09-17 接入:后端经 SDK 托管件中转并复核创建人, * 不再前端直调 flow-center——跨应用 CAS 票据 + CORS 双重外溢且"谁能撤"落在前端)。 @@ -330,13 +347,15 @@ function openPreview(item: { name?: string; filename?: string; fileid?: number;

{{ detail.title }}

- +
审批进度 {{ flowTrace.auditStatusDesc || "—" }} 流程:{{ flowTrace.nodeSummary }} - 当前节点:{{ flowTrace.currentNodes }} + 当前节点:{{ currentNodeText }}
全部审批记录
- -
-
- {{ s.label || s.nodeName || `节点${i + 1}` }} - -
-
- -
-
- {{ t.nodeName || t.node || t.taskName || `节点${i + 1}` }} - {{ t.userName || t.assigneeName || t.handlerName || "" }} - {{ t.handleTime || t.time || t.createTime || "" }} - {{ t.opinion }} -
-
- + +
@@ -544,48 +537,6 @@ function openPreview(item: { name?: string; filename?: string; fileid?: number; color: var(--red); font-size: 13px; } -.flow-timeline { - margin-top: 8px; - background: var(--panel); - border-radius: var(--r-s); - padding: 6px 10px; -} -.flow-step { - display: flex; - gap: 12px; - font-size: 13px; - color: var(--text-2); - padding: 3px 0; - border-bottom: 1px dashed var(--line); -} -.flow-step:last-child { - border-bottom: none; -} -.flow-step-node { - min-width: 120px; -} -.flow-step-user { - min-width: 90px; - color: var(--brand); -} -.flow-step-time { - color: var(--text-3); -} -.flow-step-op { - color: var(--red); -} -.flow-step-active .flow-step-node { - color: var(--brand); - font-weight: 600; -} -.flow-step-status { - font-style: normal; - color: var(--text-3); - margin-left: 4px; -} -.flow-step .flow-step-op { - font-style: normal; -} .diagram-wrap { text-align: center; min-height: 200px;