diff --git a/CHANGELOG.md b/CHANGELOG.md index 0a7193c4..1b59365a 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -11,6 +11,7 @@ - Modal/Drawer中使用VxeTable tooltip需要设置更高的z-index 防止被遮挡 - 字典(DictTag)使用tsx写法重构 +- 请假申请 按钮区域重构 **OTHERS** diff --git a/apps/web-antd/src/views/workflow/leave/index.vue b/apps/web-antd/src/views/workflow/leave/index.vue index 8e46ab00..f0224f82 100644 --- a/apps/web-antd/src/views/workflow/leave/index.vue +++ b/apps/web-antd/src/views/workflow/leave/index.vue @@ -60,11 +60,27 @@ const gridOptions: VxeGridProps = { }, // 表格全局唯一表示 保存列配置需要用到 id: 'workflow-leave-index', + cellClassName: ({ row }) => { + // 草稿状态 可点击 + if (row.status === 'draft') { + return 'cursor-pointer'; + } + }, }; const [BasicTable, tableApi] = useVbenVxeGrid({ formOptions, gridOptions, + gridEvents: { + cellClick: ({ row }) => { + // 非草稿状态 不做处理 + if (row.status !== 'draft') { + return; + } + // 查看详情 + handleInfo(row); + }, + }, }); const router = useRouter(); @@ -152,47 +168,50 @@ function handleInfo(row: Required) {