From f60840bcb8047a6ce98b52c2e099a2672671f81c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E5=90=B4=E7=BA=A2=E5=85=B5?= <374362909@qq.com> Date: Wed, 4 Mar 2026 12:41:20 +0800 Subject: [PATCH] =?UTF-8?q?fix:=20=E4=BF=AE=E5=A4=8D=E5=BE=85=E5=8A=9E?= =?UTF-8?q?=E6=95=B0=E6=8D=AE=E8=A7=A3=E6=9E=90=EF=BC=8C=E8=B0=83=E6=95=B4?= =?UTF-8?q?=E5=AD=97=E6=AE=B5=E6=98=BE=E7=A4=BA=EF=BC=88jobName/flowName/c?= =?UTF-8?q?ode=EF=BC=89=EF=BC=8C=E4=BC=98=E5=8C=96=E7=82=B9=E5=87=BB?= =?UTF-8?q?=E8=B7=B3=E8=BD=AC?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/views/home/index.vue | 51 ++++++++++++++++------------------------ 1 file changed, 20 insertions(+), 31 deletions(-) diff --git a/src/views/home/index.vue b/src/views/home/index.vue index d514f5b..22f547e 100644 --- a/src/views/home/index.vue +++ b/src/views/home/index.vue @@ -46,10 +46,11 @@ @click="handleTodoClick(item)" >
- - {{ getPriorityText(item.priority) }} + + {{ item.flowName || '流程' }} - {{ item.title || item.taskName }} + {{ item.jobName }} + ({{ item.code }})
{{ formatTime(item.createTime) }} @@ -185,33 +186,13 @@ const formatTime = (time: string) => { } } -// 获取待办工作优先级文本 -const getPriorityText = (priority?: number) => { - const map: Record = { - 0: '普通', - 1: '重要', - 2: '紧急' - } - return map[priority || 0] || '普通' -} - -// 获取待办工作优先级类型 -const getTodoType = (priority?: number) => { - const map: Record = { - 0: 'info', - 1: 'warning', - 2: 'danger' - } - return map[priority || 0] || 'info' -} - // 加载待办工作 const loadTodoList = async () => { try { todoLoading.value = true const res = await fetchTodoPage({ current: 1, size: 10 }) if (res.code === 0 && res.data) { - todoList.value = res.data.rows || res.data || [] + todoList.value = res.data.records || res.data.rows || res.data || [] } } catch (e) { console.error('加载待办工作失败:', e) @@ -254,13 +235,15 @@ const loadMessageList = async () => { // 点击待办项 const handleTodoClick = (item: any) => { - // 根据待办类型跳转到对应页面 - if (item.businessType) { - router.push({ - path: '/stuwork/pendingwork', - query: { id: item.id } - }) - } + // 跳转到流程处理页面 + router.push({ + path: '/jsonflow/run-job/do-job', + query: { + flowInstId: item.flowInstId, + id: item.id, + runNodeId: item.runNodeId + } + }) } // 点击通知公告 @@ -435,6 +418,12 @@ onUnmounted(() => { color: var(--el-text-color-primary); } +.todo-code { + font-size: 12px; + color: var(--el-text-color-secondary); + margin-left: 4px; +} + .todo-item-right { display: flex; align-items: center;