From a2ca8c2d096cd7c711a8ef76344c84672f27d3a5 Mon Sep 17 00:00:00 2001 From: dev_ljl <2590379346@qq.com> Date: Thu, 19 Jun 2025 14:34:23 +0800 Subject: [PATCH] =?UTF-8?q?1=E3=80=81=E9=97=A8=E7=A6=81=E7=AE=A1=E7=90=86?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../{ => device}/accessControl-modal.vue | 0 .../accessControl/{ => device}/data.ts | 0 .../accessControl/{ => device}/index.vue | 0 .../permissionRules/accessControl-modal.vue | 101 +++++++ .../accessControl/permissionRules/data.ts | 256 ++++++++++++++++++ .../accessControl/permissionRules/index.vue | 182 +++++++++++++ .../accessControl-modal.vue | 101 +++++++ .../accessControl/permissionSettings/data.ts | 256 ++++++++++++++++++ .../permissionSettings/index.vue | 182 +++++++++++++ .../useRecord/accessControl-modal.vue | 101 +++++++ .../property/accessControl/useRecord/data.ts | 256 ++++++++++++++++++ .../accessControl/useRecord/index.vue | 182 +++++++++++++ 12 files changed, 1617 insertions(+) rename apps/web-antd/src/views/property/accessControl/{ => device}/accessControl-modal.vue (100%) rename apps/web-antd/src/views/property/accessControl/{ => device}/data.ts (100%) rename apps/web-antd/src/views/property/accessControl/{ => device}/index.vue (100%) create mode 100644 apps/web-antd/src/views/property/accessControl/permissionRules/accessControl-modal.vue create mode 100644 apps/web-antd/src/views/property/accessControl/permissionRules/data.ts create mode 100644 apps/web-antd/src/views/property/accessControl/permissionRules/index.vue create mode 100644 apps/web-antd/src/views/property/accessControl/permissionSettings/accessControl-modal.vue create mode 100644 apps/web-antd/src/views/property/accessControl/permissionSettings/data.ts create mode 100644 apps/web-antd/src/views/property/accessControl/permissionSettings/index.vue create mode 100644 apps/web-antd/src/views/property/accessControl/useRecord/accessControl-modal.vue create mode 100644 apps/web-antd/src/views/property/accessControl/useRecord/data.ts create mode 100644 apps/web-antd/src/views/property/accessControl/useRecord/index.vue diff --git a/apps/web-antd/src/views/property/accessControl/accessControl-modal.vue b/apps/web-antd/src/views/property/accessControl/device/accessControl-modal.vue similarity index 100% rename from apps/web-antd/src/views/property/accessControl/accessControl-modal.vue rename to apps/web-antd/src/views/property/accessControl/device/accessControl-modal.vue diff --git a/apps/web-antd/src/views/property/accessControl/data.ts b/apps/web-antd/src/views/property/accessControl/device/data.ts similarity index 100% rename from apps/web-antd/src/views/property/accessControl/data.ts rename to apps/web-antd/src/views/property/accessControl/device/data.ts diff --git a/apps/web-antd/src/views/property/accessControl/index.vue b/apps/web-antd/src/views/property/accessControl/device/index.vue similarity index 100% rename from apps/web-antd/src/views/property/accessControl/index.vue rename to apps/web-antd/src/views/property/accessControl/device/index.vue diff --git a/apps/web-antd/src/views/property/accessControl/permissionRules/accessControl-modal.vue b/apps/web-antd/src/views/property/accessControl/permissionRules/accessControl-modal.vue new file mode 100644 index 00000000..6a57c482 --- /dev/null +++ b/apps/web-antd/src/views/property/accessControl/permissionRules/accessControl-modal.vue @@ -0,0 +1,101 @@ + + + + diff --git a/apps/web-antd/src/views/property/accessControl/permissionRules/data.ts b/apps/web-antd/src/views/property/accessControl/permissionRules/data.ts new file mode 100644 index 00000000..3b526b80 --- /dev/null +++ b/apps/web-antd/src/views/property/accessControl/permissionRules/data.ts @@ -0,0 +1,256 @@ +import type { FormSchemaGetter } from '#/adapter/form'; +import type { VxeGridProps } from '#/adapter/vxe-table'; + +import { getDictOptions } from '#/utils/dict'; +import { renderDict } from '#/utils/render'; + +export const querySchema: FormSchemaGetter = () => [ + { + component: 'Input', + fieldName: 'accessCode', + label: '门禁设备编码', + }, + { + component: 'Input', + fieldName: 'accessName', + label: '门禁名称', + }, + { + component: 'Input', + fieldName: 'communityCode', + label: '园区编码', + }, + { + component: 'Input', + fieldName: 'buildingCode', + label: '建筑编码', + }, + { + component: 'Input', + fieldName: 'accessIp', + label: '门禁设备ip', + }, + { + component: 'Input', + fieldName: 'accessPort', + label: '端口', + }, + { + component: 'Input', + fieldName: 'accssType', + label: '门禁设备类型', + }, + { + component: 'Input', + fieldName: 'factoryCode', + label: '工厂编码', + }, + { + component: 'Select', + componentProps: { + // 可选从DictEnum中获取 DictEnum.WY_KZKLX 便于维护 + options: getDictOptions('wy_kzklx'), + }, + fieldName: 'controlType', + label: '控制卡类型:1-系统,2-E8', + }, + { + component: 'Input', + fieldName: 'controlCode', + label: '控制卡类型编码', + }, + { + component: 'Input', + fieldName: 'outCode', + label: '外部编码', + }, + { + component: 'Input', + fieldName: 'orgCode', + label: '组织编码', + }, + { + component: 'Input', + fieldName: 'dataState', + label: '数据状态:1有效,0无效', + }, + { + component: 'Input', + fieldName: 'searchValue', + label: '搜索值', + }, +]; + +// 需要使用i18n注意这里要改成getter形式 否则切换语言不会刷新 +// export const columns: () => VxeGridProps['columns'] = () => [ +export const columns: VxeGridProps['columns'] = [ + { type: 'checkbox', width: 60 }, + { + title: '主键', + field: 'id', + }, + { + title: '门禁设备编码', + field: 'accessCode', + }, + { + title: '门禁名称', + field: 'accessName', + }, + { + title: '园区编码', + field: 'communityCode', + }, + { + title: '建筑编码', + field: 'buildingCode', + }, + { + title: '门禁设备ip', + field: 'accessIp', + }, + { + title: '端口', + field: 'accessPort', + }, + { + title: '门禁设备类型', + field: 'accssType', + }, + { + title: '工厂编码', + field: 'factoryCode', + }, + { + title: '控制卡类型:1-系统,2-E8', + field: 'controlType', + slots: { + default: ({ row }) => { + // 可选从DictEnum中获取 DictEnum.WY_KZKLX 便于维护 + return renderDict(row.controlType, 'wy_kzklx'); + }, + }, + }, + { + title: '控制卡类型编码', + field: 'controlCode', + }, + { + title: '外部编码', + field: 'outCode', + }, + { + title: '组织编码', + field: 'orgCode', + }, + { + title: '数据状态:1有效,0无效', + field: 'dataState', + }, + { + title: '搜索值', + field: 'searchValue', + }, + { + field: 'action', + fixed: 'right', + slots: { default: 'action' }, + title: '操作', + width: 180, + }, +]; + +export const modalSchema: FormSchemaGetter = () => [ + { + label: '主键', + fieldName: 'id', + component: 'Input', + dependencies: { + show: () => false, + triggerFields: [''], + }, + }, + { + label: '门禁设备编码', + fieldName: 'accessCode', + component: 'Input', + rules: 'required', + }, + { + label: '门禁名称', + fieldName: 'accessName', + component: 'Input', + rules: 'required', + }, + { + label: '园区编码', + fieldName: 'communityCode', + component: 'Input', + rules: 'required', + }, + { + label: '建筑编码', + fieldName: 'buildingCode', + component: 'Input', + rules: 'required', + }, + { + label: '门禁设备ip', + fieldName: 'accessIp', + component: 'Input', + }, + { + label: '端口', + fieldName: 'accessPort', + component: 'Input', + }, + { + label: '门禁设备类型', + fieldName: 'accssType', + component: 'Input', + rules: 'required', + }, + { + label: '工厂编码', + fieldName: 'factoryCode', + component: 'Input', + rules: 'required', + }, + { + label: '控制卡类型:1-系统,2-E8', + fieldName: 'controlType', + component: 'Select', + componentProps: { + // 可选从DictEnum中获取 DictEnum.WY_KZKLX 便于维护 + options: getDictOptions('wy_kzklx'), + }, + rules: 'selectRequired', + }, + { + label: '控制卡类型编码', + fieldName: 'controlCode', + component: 'Input', + }, + { + label: '外部编码', + fieldName: 'outCode', + component: 'Input', + }, + { + label: '组织编码', + fieldName: 'orgCode', + component: 'Input', + rules: 'required', + }, + { + label: '数据状态:1有效,0无效', + fieldName: 'dataState', + component: 'Input', + rules: 'required', + }, + { + label: '搜索值', + fieldName: 'searchValue', + component: 'Input', + }, +]; diff --git a/apps/web-antd/src/views/property/accessControl/permissionRules/index.vue b/apps/web-antd/src/views/property/accessControl/permissionRules/index.vue new file mode 100644 index 00000000..27a03d8a --- /dev/null +++ b/apps/web-antd/src/views/property/accessControl/permissionRules/index.vue @@ -0,0 +1,182 @@ + + + diff --git a/apps/web-antd/src/views/property/accessControl/permissionSettings/accessControl-modal.vue b/apps/web-antd/src/views/property/accessControl/permissionSettings/accessControl-modal.vue new file mode 100644 index 00000000..6a57c482 --- /dev/null +++ b/apps/web-antd/src/views/property/accessControl/permissionSettings/accessControl-modal.vue @@ -0,0 +1,101 @@ + + + + diff --git a/apps/web-antd/src/views/property/accessControl/permissionSettings/data.ts b/apps/web-antd/src/views/property/accessControl/permissionSettings/data.ts new file mode 100644 index 00000000..3b526b80 --- /dev/null +++ b/apps/web-antd/src/views/property/accessControl/permissionSettings/data.ts @@ -0,0 +1,256 @@ +import type { FormSchemaGetter } from '#/adapter/form'; +import type { VxeGridProps } from '#/adapter/vxe-table'; + +import { getDictOptions } from '#/utils/dict'; +import { renderDict } from '#/utils/render'; + +export const querySchema: FormSchemaGetter = () => [ + { + component: 'Input', + fieldName: 'accessCode', + label: '门禁设备编码', + }, + { + component: 'Input', + fieldName: 'accessName', + label: '门禁名称', + }, + { + component: 'Input', + fieldName: 'communityCode', + label: '园区编码', + }, + { + component: 'Input', + fieldName: 'buildingCode', + label: '建筑编码', + }, + { + component: 'Input', + fieldName: 'accessIp', + label: '门禁设备ip', + }, + { + component: 'Input', + fieldName: 'accessPort', + label: '端口', + }, + { + component: 'Input', + fieldName: 'accssType', + label: '门禁设备类型', + }, + { + component: 'Input', + fieldName: 'factoryCode', + label: '工厂编码', + }, + { + component: 'Select', + componentProps: { + // 可选从DictEnum中获取 DictEnum.WY_KZKLX 便于维护 + options: getDictOptions('wy_kzklx'), + }, + fieldName: 'controlType', + label: '控制卡类型:1-系统,2-E8', + }, + { + component: 'Input', + fieldName: 'controlCode', + label: '控制卡类型编码', + }, + { + component: 'Input', + fieldName: 'outCode', + label: '外部编码', + }, + { + component: 'Input', + fieldName: 'orgCode', + label: '组织编码', + }, + { + component: 'Input', + fieldName: 'dataState', + label: '数据状态:1有效,0无效', + }, + { + component: 'Input', + fieldName: 'searchValue', + label: '搜索值', + }, +]; + +// 需要使用i18n注意这里要改成getter形式 否则切换语言不会刷新 +// export const columns: () => VxeGridProps['columns'] = () => [ +export const columns: VxeGridProps['columns'] = [ + { type: 'checkbox', width: 60 }, + { + title: '主键', + field: 'id', + }, + { + title: '门禁设备编码', + field: 'accessCode', + }, + { + title: '门禁名称', + field: 'accessName', + }, + { + title: '园区编码', + field: 'communityCode', + }, + { + title: '建筑编码', + field: 'buildingCode', + }, + { + title: '门禁设备ip', + field: 'accessIp', + }, + { + title: '端口', + field: 'accessPort', + }, + { + title: '门禁设备类型', + field: 'accssType', + }, + { + title: '工厂编码', + field: 'factoryCode', + }, + { + title: '控制卡类型:1-系统,2-E8', + field: 'controlType', + slots: { + default: ({ row }) => { + // 可选从DictEnum中获取 DictEnum.WY_KZKLX 便于维护 + return renderDict(row.controlType, 'wy_kzklx'); + }, + }, + }, + { + title: '控制卡类型编码', + field: 'controlCode', + }, + { + title: '外部编码', + field: 'outCode', + }, + { + title: '组织编码', + field: 'orgCode', + }, + { + title: '数据状态:1有效,0无效', + field: 'dataState', + }, + { + title: '搜索值', + field: 'searchValue', + }, + { + field: 'action', + fixed: 'right', + slots: { default: 'action' }, + title: '操作', + width: 180, + }, +]; + +export const modalSchema: FormSchemaGetter = () => [ + { + label: '主键', + fieldName: 'id', + component: 'Input', + dependencies: { + show: () => false, + triggerFields: [''], + }, + }, + { + label: '门禁设备编码', + fieldName: 'accessCode', + component: 'Input', + rules: 'required', + }, + { + label: '门禁名称', + fieldName: 'accessName', + component: 'Input', + rules: 'required', + }, + { + label: '园区编码', + fieldName: 'communityCode', + component: 'Input', + rules: 'required', + }, + { + label: '建筑编码', + fieldName: 'buildingCode', + component: 'Input', + rules: 'required', + }, + { + label: '门禁设备ip', + fieldName: 'accessIp', + component: 'Input', + }, + { + label: '端口', + fieldName: 'accessPort', + component: 'Input', + }, + { + label: '门禁设备类型', + fieldName: 'accssType', + component: 'Input', + rules: 'required', + }, + { + label: '工厂编码', + fieldName: 'factoryCode', + component: 'Input', + rules: 'required', + }, + { + label: '控制卡类型:1-系统,2-E8', + fieldName: 'controlType', + component: 'Select', + componentProps: { + // 可选从DictEnum中获取 DictEnum.WY_KZKLX 便于维护 + options: getDictOptions('wy_kzklx'), + }, + rules: 'selectRequired', + }, + { + label: '控制卡类型编码', + fieldName: 'controlCode', + component: 'Input', + }, + { + label: '外部编码', + fieldName: 'outCode', + component: 'Input', + }, + { + label: '组织编码', + fieldName: 'orgCode', + component: 'Input', + rules: 'required', + }, + { + label: '数据状态:1有效,0无效', + fieldName: 'dataState', + component: 'Input', + rules: 'required', + }, + { + label: '搜索值', + fieldName: 'searchValue', + component: 'Input', + }, +]; diff --git a/apps/web-antd/src/views/property/accessControl/permissionSettings/index.vue b/apps/web-antd/src/views/property/accessControl/permissionSettings/index.vue new file mode 100644 index 00000000..27a03d8a --- /dev/null +++ b/apps/web-antd/src/views/property/accessControl/permissionSettings/index.vue @@ -0,0 +1,182 @@ + + + diff --git a/apps/web-antd/src/views/property/accessControl/useRecord/accessControl-modal.vue b/apps/web-antd/src/views/property/accessControl/useRecord/accessControl-modal.vue new file mode 100644 index 00000000..6a57c482 --- /dev/null +++ b/apps/web-antd/src/views/property/accessControl/useRecord/accessControl-modal.vue @@ -0,0 +1,101 @@ + + + + diff --git a/apps/web-antd/src/views/property/accessControl/useRecord/data.ts b/apps/web-antd/src/views/property/accessControl/useRecord/data.ts new file mode 100644 index 00000000..3b526b80 --- /dev/null +++ b/apps/web-antd/src/views/property/accessControl/useRecord/data.ts @@ -0,0 +1,256 @@ +import type { FormSchemaGetter } from '#/adapter/form'; +import type { VxeGridProps } from '#/adapter/vxe-table'; + +import { getDictOptions } from '#/utils/dict'; +import { renderDict } from '#/utils/render'; + +export const querySchema: FormSchemaGetter = () => [ + { + component: 'Input', + fieldName: 'accessCode', + label: '门禁设备编码', + }, + { + component: 'Input', + fieldName: 'accessName', + label: '门禁名称', + }, + { + component: 'Input', + fieldName: 'communityCode', + label: '园区编码', + }, + { + component: 'Input', + fieldName: 'buildingCode', + label: '建筑编码', + }, + { + component: 'Input', + fieldName: 'accessIp', + label: '门禁设备ip', + }, + { + component: 'Input', + fieldName: 'accessPort', + label: '端口', + }, + { + component: 'Input', + fieldName: 'accssType', + label: '门禁设备类型', + }, + { + component: 'Input', + fieldName: 'factoryCode', + label: '工厂编码', + }, + { + component: 'Select', + componentProps: { + // 可选从DictEnum中获取 DictEnum.WY_KZKLX 便于维护 + options: getDictOptions('wy_kzklx'), + }, + fieldName: 'controlType', + label: '控制卡类型:1-系统,2-E8', + }, + { + component: 'Input', + fieldName: 'controlCode', + label: '控制卡类型编码', + }, + { + component: 'Input', + fieldName: 'outCode', + label: '外部编码', + }, + { + component: 'Input', + fieldName: 'orgCode', + label: '组织编码', + }, + { + component: 'Input', + fieldName: 'dataState', + label: '数据状态:1有效,0无效', + }, + { + component: 'Input', + fieldName: 'searchValue', + label: '搜索值', + }, +]; + +// 需要使用i18n注意这里要改成getter形式 否则切换语言不会刷新 +// export const columns: () => VxeGridProps['columns'] = () => [ +export const columns: VxeGridProps['columns'] = [ + { type: 'checkbox', width: 60 }, + { + title: '主键', + field: 'id', + }, + { + title: '门禁设备编码', + field: 'accessCode', + }, + { + title: '门禁名称', + field: 'accessName', + }, + { + title: '园区编码', + field: 'communityCode', + }, + { + title: '建筑编码', + field: 'buildingCode', + }, + { + title: '门禁设备ip', + field: 'accessIp', + }, + { + title: '端口', + field: 'accessPort', + }, + { + title: '门禁设备类型', + field: 'accssType', + }, + { + title: '工厂编码', + field: 'factoryCode', + }, + { + title: '控制卡类型:1-系统,2-E8', + field: 'controlType', + slots: { + default: ({ row }) => { + // 可选从DictEnum中获取 DictEnum.WY_KZKLX 便于维护 + return renderDict(row.controlType, 'wy_kzklx'); + }, + }, + }, + { + title: '控制卡类型编码', + field: 'controlCode', + }, + { + title: '外部编码', + field: 'outCode', + }, + { + title: '组织编码', + field: 'orgCode', + }, + { + title: '数据状态:1有效,0无效', + field: 'dataState', + }, + { + title: '搜索值', + field: 'searchValue', + }, + { + field: 'action', + fixed: 'right', + slots: { default: 'action' }, + title: '操作', + width: 180, + }, +]; + +export const modalSchema: FormSchemaGetter = () => [ + { + label: '主键', + fieldName: 'id', + component: 'Input', + dependencies: { + show: () => false, + triggerFields: [''], + }, + }, + { + label: '门禁设备编码', + fieldName: 'accessCode', + component: 'Input', + rules: 'required', + }, + { + label: '门禁名称', + fieldName: 'accessName', + component: 'Input', + rules: 'required', + }, + { + label: '园区编码', + fieldName: 'communityCode', + component: 'Input', + rules: 'required', + }, + { + label: '建筑编码', + fieldName: 'buildingCode', + component: 'Input', + rules: 'required', + }, + { + label: '门禁设备ip', + fieldName: 'accessIp', + component: 'Input', + }, + { + label: '端口', + fieldName: 'accessPort', + component: 'Input', + }, + { + label: '门禁设备类型', + fieldName: 'accssType', + component: 'Input', + rules: 'required', + }, + { + label: '工厂编码', + fieldName: 'factoryCode', + component: 'Input', + rules: 'required', + }, + { + label: '控制卡类型:1-系统,2-E8', + fieldName: 'controlType', + component: 'Select', + componentProps: { + // 可选从DictEnum中获取 DictEnum.WY_KZKLX 便于维护 + options: getDictOptions('wy_kzklx'), + }, + rules: 'selectRequired', + }, + { + label: '控制卡类型编码', + fieldName: 'controlCode', + component: 'Input', + }, + { + label: '外部编码', + fieldName: 'outCode', + component: 'Input', + }, + { + label: '组织编码', + fieldName: 'orgCode', + component: 'Input', + rules: 'required', + }, + { + label: '数据状态:1有效,0无效', + fieldName: 'dataState', + component: 'Input', + rules: 'required', + }, + { + label: '搜索值', + fieldName: 'searchValue', + component: 'Input', + }, +]; diff --git a/apps/web-antd/src/views/property/accessControl/useRecord/index.vue b/apps/web-antd/src/views/property/accessControl/useRecord/index.vue new file mode 100644 index 00000000..27a03d8a --- /dev/null +++ b/apps/web-antd/src/views/property/accessControl/useRecord/index.vue @@ -0,0 +1,182 @@ + + +