[ysch-flow] S2.1 修向导④条件查看按钮(P0,Vue3 render 形态)

Onboarding 向导④流程清单的「查看条件」入口断裂两处:Button 未从 view-ui-plus 导入,
且 render 用了 Vue2 的 { props: {...}, on: { click } } 形态——Vue3 h() 把它们当普通
prop 名传入,点击不绑、type/size 全丢,变量契约自查入口因此不可用(实测报告缺陷#2)。
改为 h(Button, { type, size, onClick }, () => 文本);同仓 AppSetting「查推送日志」列
同一写法残留一并修正。npm run build 绿,diff 仅涉事 2 文件 4 行。
This commit is contained in:
chenxing
2026-10-17 23:06:57 +08:00
parent 98ea069691
commit 650665224c
2 changed files with 5 additions and 4 deletions
+3 -2
View File
@@ -410,8 +410,9 @@ const healthColumns = [
align: "center",
render: (h: any, p: any) =>
h(Button, {
props: { type: "text", size: "small" },
on: { click: () => onViewLogs(p.row) },
type: "text",
size: "small",
onClick: () => onViewLogs(p.row),
}, () => "查推送日志"),
},
];
+2 -2
View File
@@ -5,7 +5,7 @@
// 零新增表、零新增写接口。配置生成器对齐《子应用接入流程中心规范.md》§7.2/§7.5。
// 方案文档:docs/流程中心接入向导与配置生成器-实施方案-20261015.md
import { ref, computed, onMounted } from "vue";
import { Message, Tag } from "view-ui-plus";
import { Message, Tag, Button } from "view-ui-plus";
import { flowApi } from "@/api/module/flow";
import Utils from "@/utils";
import { extractExprVars, EXPR_BUILTIN_VARS } from "@/views/flow/admin/def-editor/model";
@@ -589,7 +589,7 @@ async function goto(n: number) {
{ title: '流程', key: 'name', minWidth: 180 },
{ title: 'flowGuid', key: 'flowGuid', minWidth: 200 },
{ title: '状态', width: 90, align: 'center', render: (h: any, p: any) => h(Tag, { color: p.row.status === 1 ? 'green' : p.row.status === 0 ? 'orange' : 'gray' }, () => DEF_STATUS[p.row.status] || p.row.status) },
{ title: '操作', width: 90, align: 'center', render: (h: any, p: any) => h(Button, { props: { type: 'text', size: 'small' }, on: { click: () => inspectDef(p.row.id) } }, () => '查看条件') },
{ title: '操作', width: 90, align: 'center', render: (h: any, p: any) => h(Button, { type: 'text', size: 'small', onClick: () => inspectDef(p.row.id) }, () => '查看条件') },
]" :data="defs" :loading="defLoading" size="small" max-height="220"
no-data-text="该应用无流程定义(先回第①步确认应用,或去流程定义页新建)" />
</div>