diff --git a/apps/web-antd/src/views/bpm/category/data.ts b/apps/web-antd/src/views/bpm/category/data.ts index 1df6ba2de..4a4b86aa2 100644 --- a/apps/web-antd/src/views/bpm/category/data.ts +++ b/apps/web-antd/src/views/bpm/category/data.ts @@ -1,13 +1,9 @@ import type { VbenFormSchema } from '#/adapter/form'; -import type { OnActionClickFn, VxeTableGridOptions } from '#/adapter/vxe-table'; -import type { BpmCategoryApi } from '#/api/bpm/category'; - -import { useAccess } from '@vben/access'; +import type { VxeTableGridOptions } from '#/adapter/vxe-table'; import { z } from '#/adapter/form'; import { CommonStatusEnum, DICT_TYPE, getDictOptions } from '#/utils'; -const { hasAccessByCodes } = useAccess(); /** 新增/修改的表单 */ export function useFormSchema(): VbenFormSchema[] { return [ @@ -106,9 +102,7 @@ export function useGridFormSchema(): VbenFormSchema[] { } /** 列表的字段 */ -export function useGridColumns( - onActionClick: OnActionClickFn, -): VxeTableGridOptions['columns'] { +export function useGridColumns(): VxeTableGridOptions['columns'] { return [ { field: 'id', @@ -146,29 +140,10 @@ export function useGridColumns( formatter: 'formatDateTime', }, { - field: 'operation', title: '操作', - minWidth: 180, - align: 'center', + width: 180, fixed: 'right', - cellRender: { - attrs: { - nameField: 'name', - nameTitle: '流程分类', - onClick: onActionClick, - }, - name: 'CellOperation', - options: [ - { - code: 'edit', - show: hasAccessByCodes(['bpm:category:update']), - }, - { - code: 'delete', - show: hasAccessByCodes(['bpm:category:delete']), - }, - ], - }, + slots: { default: 'actions' }, }, ]; } diff --git a/apps/web-antd/src/views/bpm/category/index.vue b/apps/web-antd/src/views/bpm/category/index.vue index 8dd26b7c3..a4abb556e 100644 --- a/apps/web-antd/src/views/bpm/category/index.vue +++ b/apps/web-antd/src/views/bpm/category/index.vue @@ -1,16 +1,12 @@