From a107323e36d443acc8e8c8c9b6bbde284561f34a Mon Sep 17 00:00:00 2001
From: dev_ljl <2590379346@qq.com>
Date: Tue, 24 Jun 2025 14:52:45 +0800
Subject: [PATCH] =?UTF-8?q?1=E3=80=81=E8=B5=84=E4=BA=A7=E7=AE=A1=E7=90=86?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
.../{ => assetManage}/application/index.ts | 0
.../{ => assetManage}/application/model.d.ts | 0
.../property/{ => assetManage}/asset/index.ts | 0
.../{ => assetManage}/asset/model.d.ts | 0
.../property/{ => assetManage}/depot/index.ts | 0
.../{ => assetManage}/depot/model.d.ts | 0
.../property/{ => assetManage}/log/index.ts | 0
.../property/{ => assetManage}/log/model.d.ts | 0
.../{ => assetManage}/suppliers/index.ts | 0
.../{ => assetManage}/suppliers/model.d.ts | 0
...ntrol-modal.vue => accessControlModal.vue} | 0
.../property/accessControl/device/data.ts | 125 ++++--------------
.../property/accessControl/device/index.vue | 14 +-
.../application/application-modal.vue | 2 +-
.../{ => assetManage}/application/data.ts | 0
.../{ => assetManage}/application/index.vue | 25 +---
.../{ => assetManage}/asset/asset-modal.vue | 2 +-
.../property/{ => assetManage}/asset/data.ts | 76 +++--------
.../{ => assetManage}/asset/index.vue | 30 +----
.../views/property/assetManage/depot/data.ts | 110 +++++++++++++++
.../assetManage/depot/depot-detail.vue | 69 ++++++++++
.../{ => assetManage}/depot/depot-modal.vue | 8 +-
.../{ => assetManage}/depot/index.vue | 60 ++++++---
.../property/{ => assetManage}/log/data.ts | 0
.../property/{ => assetManage}/log/index.vue | 12 +-
.../{ => assetManage}/log/log-modal.vue | 2 +-
.../{ => assetManage}/suppliers/data.ts | 100 +++++++-------
.../{ => assetManage}/suppliers/index.vue | 60 +++++----
.../suppliers/suppliers-detail.vue | 77 +++++++++++
.../suppliers/suppliers-modal.vue | 8 +-
.../web-antd/src/views/property/depot/data.ts | 95 -------------
.../views/property/resident/person/index.vue | 5 +
.../property/resident/person/person-modal.vue | 5 +-
.../resident/person/query-unit-list.vue | 26 +---
.../resident/person/query-user-list.vue | 52 ++++++--
.../src/views/property/resident/unit/data.ts | 3 +-
.../views/property/resident/unit/index.vue | 9 +-
37 files changed, 521 insertions(+), 454 deletions(-)
rename apps/web-antd/src/api/property/{ => assetManage}/application/index.ts (100%)
rename apps/web-antd/src/api/property/{ => assetManage}/application/model.d.ts (100%)
rename apps/web-antd/src/api/property/{ => assetManage}/asset/index.ts (100%)
rename apps/web-antd/src/api/property/{ => assetManage}/asset/model.d.ts (100%)
rename apps/web-antd/src/api/property/{ => assetManage}/depot/index.ts (100%)
rename apps/web-antd/src/api/property/{ => assetManage}/depot/model.d.ts (100%)
rename apps/web-antd/src/api/property/{ => assetManage}/log/index.ts (100%)
rename apps/web-antd/src/api/property/{ => assetManage}/log/model.d.ts (100%)
rename apps/web-antd/src/api/property/{ => assetManage}/suppliers/index.ts (100%)
rename apps/web-antd/src/api/property/{ => assetManage}/suppliers/model.d.ts (100%)
rename apps/web-antd/src/views/property/accessControl/device/{accessControl-modal.vue => accessControlModal.vue} (100%)
rename apps/web-antd/src/views/property/{ => assetManage}/application/application-modal.vue (98%)
rename apps/web-antd/src/views/property/{ => assetManage}/application/data.ts (100%)
rename apps/web-antd/src/views/property/{ => assetManage}/application/index.vue (86%)
rename apps/web-antd/src/views/property/{ => assetManage}/asset/asset-modal.vue (99%)
rename apps/web-antd/src/views/property/{ => assetManage}/asset/data.ts (67%)
rename apps/web-antd/src/views/property/{ => assetManage}/asset/index.vue (82%)
create mode 100644 apps/web-antd/src/views/property/assetManage/depot/data.ts
create mode 100644 apps/web-antd/src/views/property/assetManage/depot/depot-detail.vue
rename apps/web-antd/src/views/property/{ => assetManage}/depot/depot-modal.vue (96%)
rename apps/web-antd/src/views/property/{ => assetManage}/depot/index.vue (76%)
rename apps/web-antd/src/views/property/{ => assetManage}/log/data.ts (100%)
rename apps/web-antd/src/views/property/{ => assetManage}/log/index.vue (95%)
rename apps/web-antd/src/views/property/{ => assetManage}/log/log-modal.vue (96%)
rename apps/web-antd/src/views/property/{ => assetManage}/suppliers/data.ts (67%)
rename apps/web-antd/src/views/property/{ => assetManage}/suppliers/index.vue (76%)
create mode 100644 apps/web-antd/src/views/property/assetManage/suppliers/suppliers-detail.vue
rename apps/web-antd/src/views/property/{ => assetManage}/suppliers/suppliers-modal.vue (95%)
delete mode 100644 apps/web-antd/src/views/property/depot/data.ts
diff --git a/apps/web-antd/src/api/property/application/index.ts b/apps/web-antd/src/api/property/assetManage/application/index.ts
similarity index 100%
rename from apps/web-antd/src/api/property/application/index.ts
rename to apps/web-antd/src/api/property/assetManage/application/index.ts
diff --git a/apps/web-antd/src/api/property/application/model.d.ts b/apps/web-antd/src/api/property/assetManage/application/model.d.ts
similarity index 100%
rename from apps/web-antd/src/api/property/application/model.d.ts
rename to apps/web-antd/src/api/property/assetManage/application/model.d.ts
diff --git a/apps/web-antd/src/api/property/asset/index.ts b/apps/web-antd/src/api/property/assetManage/asset/index.ts
similarity index 100%
rename from apps/web-antd/src/api/property/asset/index.ts
rename to apps/web-antd/src/api/property/assetManage/asset/index.ts
diff --git a/apps/web-antd/src/api/property/asset/model.d.ts b/apps/web-antd/src/api/property/assetManage/asset/model.d.ts
similarity index 100%
rename from apps/web-antd/src/api/property/asset/model.d.ts
rename to apps/web-antd/src/api/property/assetManage/asset/model.d.ts
diff --git a/apps/web-antd/src/api/property/depot/index.ts b/apps/web-antd/src/api/property/assetManage/depot/index.ts
similarity index 100%
rename from apps/web-antd/src/api/property/depot/index.ts
rename to apps/web-antd/src/api/property/assetManage/depot/index.ts
diff --git a/apps/web-antd/src/api/property/depot/model.d.ts b/apps/web-antd/src/api/property/assetManage/depot/model.d.ts
similarity index 100%
rename from apps/web-antd/src/api/property/depot/model.d.ts
rename to apps/web-antd/src/api/property/assetManage/depot/model.d.ts
diff --git a/apps/web-antd/src/api/property/log/index.ts b/apps/web-antd/src/api/property/assetManage/log/index.ts
similarity index 100%
rename from apps/web-antd/src/api/property/log/index.ts
rename to apps/web-antd/src/api/property/assetManage/log/index.ts
diff --git a/apps/web-antd/src/api/property/log/model.d.ts b/apps/web-antd/src/api/property/assetManage/log/model.d.ts
similarity index 100%
rename from apps/web-antd/src/api/property/log/model.d.ts
rename to apps/web-antd/src/api/property/assetManage/log/model.d.ts
diff --git a/apps/web-antd/src/api/property/suppliers/index.ts b/apps/web-antd/src/api/property/assetManage/suppliers/index.ts
similarity index 100%
rename from apps/web-antd/src/api/property/suppliers/index.ts
rename to apps/web-antd/src/api/property/assetManage/suppliers/index.ts
diff --git a/apps/web-antd/src/api/property/suppliers/model.d.ts b/apps/web-antd/src/api/property/assetManage/suppliers/model.d.ts
similarity index 100%
rename from apps/web-antd/src/api/property/suppliers/model.d.ts
rename to apps/web-antd/src/api/property/assetManage/suppliers/model.d.ts
diff --git a/apps/web-antd/src/views/property/accessControl/device/accessControl-modal.vue b/apps/web-antd/src/views/property/accessControl/device/accessControlModal.vue
similarity index 100%
rename from apps/web-antd/src/views/property/accessControl/device/accessControl-modal.vue
rename to apps/web-antd/src/views/property/accessControl/device/accessControlModal.vue
diff --git a/apps/web-antd/src/views/property/accessControl/device/data.ts b/apps/web-antd/src/views/property/accessControl/device/data.ts
index 44097fbd..aec4898c 100644
--- a/apps/web-antd/src/views/property/accessControl/device/data.ts
+++ b/apps/web-antd/src/views/property/accessControl/device/data.ts
@@ -1,100 +1,49 @@
-import type { FormSchemaGetter } from '#/adapter/form';
-import type { VxeGridProps } from '#/adapter/vxe-table';
+import type {FormSchemaGetter} from '#/adapter/form';
+import type {VxeGridProps} from '#/adapter/vxe-table';
-import { getDictOptions } from '#/utils/dict';
-import { renderDict } from '#/utils/render';
+import {getDictOptions} from '#/utils/dict';
+import {renderDict} from '#/utils/render';
export const querySchema: FormSchemaGetter = () => [
{
component: 'Input',
fieldName: 'accessCode',
- label: '门禁设备编码',
+ 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: 'accessType',
- label: '门禁设备类型',
- },
- {
- component: 'Input',
- fieldName: 'factoryCode',
- label: '工厂编码',
+ label: '设备名称',
},
{
component: 'Select',
+ fieldName: 'controlType',
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: '搜索值',
+ label: '控制卡类型',
},
];
// 需要使用i18n注意这里要改成getter形式 否则切换语言不会刷新
// export const columns: () => VxeGridProps['columns'] = () => [
export const columns: VxeGridProps['columns'] = [
- { type: 'checkbox', width: 60 },
+ {type: 'checkbox', width: 60},
{
- title: '主键',
+ title: '序号',
field: 'id',
+ slots: {
+ default: ({rowIndex}) => {
+ return rowIndex + 1;
+ },
+ },
},
{
- title: '门禁设备编码',
+ title: '设备编码',
field: 'accessCode',
},
{
- title: '门禁名称',
+ title: '设备名称',
field: 'accessName',
},
{
@@ -106,7 +55,7 @@ export const columns: VxeGridProps['columns'] = [
field: 'buildingCode',
},
{
- title: '门禁设备ip',
+ title: '设备IP',
field: 'accessIp',
},
{
@@ -114,7 +63,7 @@ export const columns: VxeGridProps['columns'] = [
field: 'accessPort',
},
{
- title: '门禁设备类型',
+ title: '设备类型',
field: 'accessType',
},
{
@@ -122,11 +71,10 @@ export const columns: VxeGridProps['columns'] = [
field: 'factoryCode',
},
{
- title: '控制卡类型:1-系统,2-E8',
+ title: '控制卡类型',
field: 'controlType',
slots: {
- default: ({ row }) => {
- // 可选从DictEnum中获取 DictEnum.WY_KZKLX 便于维护
+ default: ({row}) => {
return renderDict(row.controlType, 'wy_kzklx');
},
},
@@ -143,18 +91,10 @@ export const columns: VxeGridProps['columns'] = [
title: '组织编码',
field: 'orgCode',
},
- {
- title: '数据状态:1有效,0无效',
- field: 'dataState',
- },
- {
- title: '搜索值',
- field: 'searchValue',
- },
{
field: 'action',
fixed: 'right',
- slots: { default: 'action' },
+ slots: {default: 'action'},
title: '操作',
width: 180,
},
@@ -171,13 +111,13 @@ export const modalSchema: FormSchemaGetter = () => [
},
},
{
- label: '门禁设备编码',
+ label: '设备编码',
fieldName: 'accessCode',
component: 'Input',
rules: 'required',
},
{
- label: '门禁名称',
+ label: '设备名称',
fieldName: 'accessName',
component: 'Input',
rules: 'required',
@@ -195,7 +135,7 @@ export const modalSchema: FormSchemaGetter = () => [
rules: 'required',
},
{
- label: '门禁设备ip',
+ label: '设备IP',
fieldName: 'accessIp',
component: 'Input',
},
@@ -205,7 +145,7 @@ export const modalSchema: FormSchemaGetter = () => [
component: 'Input',
},
{
- label: '门禁设备类型',
+ label: '设备类型',
fieldName: 'accessType',
component: 'Input',
rules: 'required',
@@ -217,7 +157,7 @@ export const modalSchema: FormSchemaGetter = () => [
rules: 'required',
},
{
- label: '控制卡类型:1-系统,2-E8',
+ label: '控制卡类型',
fieldName: 'controlType',
component: 'Select',
componentProps: {
@@ -242,15 +182,4 @@ export const modalSchema: FormSchemaGetter = () => [
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/device/index.vue b/apps/web-antd/src/views/property/accessControl/device/index.vue
index 75d41e97..585d04cd 100644
--- a/apps/web-antd/src/views/property/accessControl/device/index.vue
+++ b/apps/web-antd/src/views/property/accessControl/device/index.vue
@@ -9,10 +9,10 @@ import { getVxePopupContainer } from '@vben/utils';
import { Modal, Popconfirm, Space } from 'ant-design-vue';
import dayjs from 'dayjs';
-import {
+import {
useVbenVxeGrid,
vxeCheckboxChecked,
- type VxeGridProps
+ type VxeGridProps
} from '#/adapter/vxe-table';
import {
@@ -23,12 +23,12 @@ import {
import type { AccessControlForm } from '#/api/property/accessControl/model';
import { commonDownloadExcel } from '#/utils/file/download';
-import accessControlModal from './accessControl-modal.vue';
+import accessControlModal from './accessControlModal.vue';
import { columns, querySchema } from './data';
const formOptions: VbenFormProps = {
commonConfig: {
- labelWidth: 80,
+ labelWidth: 100,
componentProps: {
allowClear: true,
},
@@ -126,7 +126,7 @@ function handleDownloadExcel() {
-
+
{{ $t('pages.common.delete') }}
diff --git a/apps/web-antd/src/views/property/application/application-modal.vue b/apps/web-antd/src/views/property/assetManage/application/application-modal.vue
similarity index 98%
rename from apps/web-antd/src/views/property/application/application-modal.vue
rename to apps/web-antd/src/views/property/assetManage/application/application-modal.vue
index 4a817bf5..304b9fe3 100644
--- a/apps/web-antd/src/views/property/application/application-modal.vue
+++ b/apps/web-antd/src/views/property/assetManage/application/application-modal.vue
@@ -6,7 +6,7 @@ import { $t } from '@vben/locales';
import { cloneDeep } from '@vben/utils';
import { useVbenForm } from '#/adapter/form';
-import { applicationAdd, applicationInfo, applicationUpdate } from '#/api/property/application';
+import { applicationAdd, applicationInfo, applicationUpdate } from '#/api/property/assetManage/application';
import { defaultFormValueGetter, useBeforeCloseDiff } from '#/utils/popup';
import { modalSchema } from './data';
diff --git a/apps/web-antd/src/views/property/application/data.ts b/apps/web-antd/src/views/property/assetManage/application/data.ts
similarity index 100%
rename from apps/web-antd/src/views/property/application/data.ts
rename to apps/web-antd/src/views/property/assetManage/application/data.ts
diff --git a/apps/web-antd/src/views/property/application/index.vue b/apps/web-antd/src/views/property/assetManage/application/index.vue
similarity index 86%
rename from apps/web-antd/src/views/property/application/index.vue
rename to apps/web-antd/src/views/property/assetManage/application/index.vue
index 0b4ad458..4ca020dc 100644
--- a/apps/web-antd/src/views/property/application/index.vue
+++ b/apps/web-antd/src/views/property/assetManage/application/index.vue
@@ -1,26 +1,22 @@
+
+
+
+
+
+ {{ depotDetail.depotName }}
+
+
+
+
+
+
+
+
+ {{ depotDetail.createTime}}
+
+
+ {{ depotDetail.msg}}
+
+
+
+
+
diff --git a/apps/web-antd/src/views/property/depot/depot-modal.vue b/apps/web-antd/src/views/property/assetManage/depot/depot-modal.vue
similarity index 96%
rename from apps/web-antd/src/views/property/depot/depot-modal.vue
rename to apps/web-antd/src/views/property/assetManage/depot/depot-modal.vue
index 7bf9c04b..1ce0e87f 100644
--- a/apps/web-antd/src/views/property/depot/depot-modal.vue
+++ b/apps/web-antd/src/views/property/assetManage/depot/depot-modal.vue
@@ -6,7 +6,7 @@ import { $t } from '@vben/locales';
import { cloneDeep } from '@vben/utils';
import { useVbenForm } from '#/adapter/form';
-import { depotAdd, depotInfo, depotUpdate } from '#/api/property/depot';
+import { depotAdd, depotInfo, depotUpdate } from '#/api/property/assetManage/depot';
import { defaultFormValueGetter, useBeforeCloseDiff } from '#/utils/popup';
import { modalSchema } from './data';
@@ -21,9 +21,9 @@ const title = computed(() => {
const [BasicForm, formApi] = useVbenForm({
commonConfig: {
// 默认占满两列
- formItemClass: 'col-span-2',
+ formItemClass: 'col-span-1',
// 默认label宽度 px
- labelWidth: 80,
+ labelWidth: 100,
// 通用配置项 会影响到所有表单项
componentProps: {
class: 'w-full',
@@ -43,7 +43,7 @@ const { onBeforeClose, markInitialized, resetInitialized } = useBeforeCloseDiff(
const [BasicModal, modalApi] = useVbenModal({
// 在这里更改宽度
- class: 'w-[550px]',
+ class: 'w-[70%]',
fullscreenButton: false,
onBeforeClose,
onClosed: handleClosed,
diff --git a/apps/web-antd/src/views/property/depot/index.vue b/apps/web-antd/src/views/property/assetManage/depot/index.vue
similarity index 76%
rename from apps/web-antd/src/views/property/depot/index.vue
rename to apps/web-antd/src/views/property/assetManage/depot/index.vue
index 58b6eab2..561f666e 100644
--- a/apps/web-antd/src/views/property/depot/index.vue
+++ b/apps/web-antd/src/views/property/assetManage/depot/index.vue
@@ -1,30 +1,28 @@
-
+
{{ $t('pages.common.delete') }}
@@ -152,8 +151,24 @@ function handleDownloadExcel() {
+
+ tableApi.query()"
+ />
+
+
+ {{ $t('pages.common.info') }}
+
+
diff --git a/apps/web-antd/src/views/property/log/data.ts b/apps/web-antd/src/views/property/assetManage/log/data.ts
similarity index 100%
rename from apps/web-antd/src/views/property/log/data.ts
rename to apps/web-antd/src/views/property/assetManage/log/data.ts
diff --git a/apps/web-antd/src/views/property/log/index.vue b/apps/web-antd/src/views/property/assetManage/log/index.vue
similarity index 95%
rename from apps/web-antd/src/views/property/log/index.vue
rename to apps/web-antd/src/views/property/assetManage/log/index.vue
index 56084e98..a4767f2e 100644
--- a/apps/web-antd/src/views/property/log/index.vue
+++ b/apps/web-antd/src/views/property/assetManage/log/index.vue
@@ -9,18 +9,18 @@ import { getVxePopupContainer } from '@vben/utils';
import { Modal, Popconfirm, Space } from 'ant-design-vue';
import dayjs from 'dayjs';
-import {
+import {
useVbenVxeGrid,
vxeCheckboxChecked,
- type VxeGridProps
+ type VxeGridProps
} from '#/adapter/vxe-table';
import {
logExport,
logList,
logRemove,
-} from '#/api/property/log';
-import type { LogForm } from '#/api/property/log/model';
+} from '#/api/property/assetManage/log';
+import type { LogForm } from '#/api/property/assetManage/log/model';
import { commonDownloadExcel } from '#/utils/file/download';
import logModal from './log-modal.vue';
@@ -138,8 +138,8 @@ function handleDownloadExcel() {
{{ $t('pages.common.delete') }}
diff --git a/apps/web-antd/src/views/property/log/log-modal.vue b/apps/web-antd/src/views/property/assetManage/log/log-modal.vue
similarity index 96%
rename from apps/web-antd/src/views/property/log/log-modal.vue
rename to apps/web-antd/src/views/property/assetManage/log/log-modal.vue
index a29c1112..8587663f 100644
--- a/apps/web-antd/src/views/property/log/log-modal.vue
+++ b/apps/web-antd/src/views/property/assetManage/log/log-modal.vue
@@ -6,7 +6,7 @@ import { $t } from '@vben/locales';
import { cloneDeep } from '@vben/utils';
import { useVbenForm } from '#/adapter/form';
-import { logAdd, logInfo, logUpdate } from '#/api/property/log';
+import { logAdd, logInfo, logUpdate } from '#/api/property/assetManage/log';
import { defaultFormValueGetter, useBeforeCloseDiff } from '#/utils/popup';
import { modalSchema } from './data';
diff --git a/apps/web-antd/src/views/property/suppliers/data.ts b/apps/web-antd/src/views/property/assetManage/suppliers/data.ts
similarity index 67%
rename from apps/web-antd/src/views/property/suppliers/data.ts
rename to apps/web-antd/src/views/property/assetManage/suppliers/data.ts
index cc03cf2e..8fdd40f6 100644
--- a/apps/web-antd/src/views/property/suppliers/data.ts
+++ b/apps/web-antd/src/views/property/assetManage/suppliers/data.ts
@@ -1,5 +1,7 @@
-import type { FormSchemaGetter } from '#/adapter/form';
-import type { VxeGridProps } from '#/adapter/vxe-table';
+import type {FormSchemaGetter} from '#/adapter/form';
+import type {VxeGridProps} from '#/adapter/vxe-table';
+import {getDictOptions} from "#/utils/dict";
+import {z} from "#/adapter/form";
export const querySchema: FormSchemaGetter = () => [
@@ -9,49 +11,44 @@ export const querySchema: FormSchemaGetter = () => [
label: '供应商名称',
},
{
- component: 'Textarea',
- fieldName: 'phone',
- label: '电话',
- },
- {
- component: 'Textarea',
- fieldName: 'location',
- label: '地址',
- },
- {
- component: 'Textarea',
+ component: 'Input',
fieldName: 'user',
label: '联系人',
},
{
component: 'Input',
+ fieldName: 'phone',
+ label: '电话',
+ },
+ {
+ component: 'Select',
fieldName: 'state',
label: '状态',
- },
- {
- component: 'Textarea',
- fieldName: 'bank',
- label: '开户行',
- },
- {
- component: 'Textarea',
- fieldName: 'bankNumber',
- label: '卡号',
+ componentProps:{
+ options: getDictOptions('wy_state'),
+ }
},
];
-// 需要使用i18n注意这里要改成getter形式 否则切换语言不会刷新
-// export const columns: () => VxeGridProps['columns'] = () => [
export const columns: VxeGridProps['columns'] = [
- { type: 'checkbox', width: 60 },
+ {type: 'checkbox', width: 60},
{
- title: '主键',
+ title: '序号',
field: 'id',
+ slots: {
+ default: ({rowIndex}) => {
+ return rowIndex + 1;
+ }
+ }
},
{
title: '供应商名称',
field: 'suppliersName',
},
+ {
+ title: '联系人',
+ field: 'user',
+ },
{
title: '电话',
field: 'phone',
@@ -60,14 +57,6 @@ export const columns: VxeGridProps['columns'] = [
title: '地址',
field: 'location',
},
- {
- title: '联系人',
- field: 'user',
- },
- {
- title: '状态',
- field: 'state',
- },
{
title: '开户行',
field: 'bank',
@@ -76,6 +65,11 @@ export const columns: VxeGridProps['columns'] = [
title: '卡号',
field: 'bankNumber',
},
+ {
+ title: '状态',
+ field: 'state',
+ slots: {default: 'state'}
+ },
{
title: '备注',
field: 'remark',
@@ -87,7 +81,7 @@ export const columns: VxeGridProps['columns'] = [
{
field: 'action',
fixed: 'right',
- slots: { default: 'action' },
+ slots: {default: 'action'},
title: '操作',
width: 180,
},
@@ -108,43 +102,43 @@ export const modalSchema: FormSchemaGetter = () => [
fieldName: 'suppliersName',
component: 'Input',
rules: 'required',
- },
- {
- label: '电话',
- fieldName: 'phone',
- component: 'Textarea',
- rules: 'required',
- },
- {
- label: '地址',
- fieldName: 'location',
- component: 'Textarea',
- rules: 'required',
+ formItemClass:'col-span-2'
},
{
label: '联系人',
fieldName: 'user',
- component: 'Textarea',
+ component: 'Input',
rules: 'required',
},
{
- label: '状态',
- fieldName: 'state',
+ label: '电话',
+ fieldName: 'phone',
component: 'Input',
+ rules: z.string().regex(/^1[3-9]\d{9}$/, { message: '格式错误' }),
+ },
+ {
+ label: '地址',
+ fieldName: 'location',
+ component: 'Input',
+ rules: 'required',
+ formItemClass:'col-span-2'
},
{
label: '开户行',
fieldName: 'bank',
- component: 'Textarea',
+ component: 'Input',
+ rules: 'required',
},
{
label: '卡号',
fieldName: 'bankNumber',
- component: 'Textarea',
+ component: 'Input',
+ rules: z.string().regex(/^\d{12,19}$/, { message: '格式错误' }),
},
{
label: '备注',
fieldName: 'remark',
component: 'Textarea',
+ formItemClass:'col-span-2'
},
];
diff --git a/apps/web-antd/src/views/property/suppliers/index.vue b/apps/web-antd/src/views/property/assetManage/suppliers/index.vue
similarity index 76%
rename from apps/web-antd/src/views/property/suppliers/index.vue
rename to apps/web-antd/src/views/property/assetManage/suppliers/index.vue
index 7f1722d3..28fb52b3 100644
--- a/apps/web-antd/src/views/property/suppliers/index.vue
+++ b/apps/web-antd/src/views/property/assetManage/suppliers/index.vue
@@ -1,30 +1,28 @@
@@ -138,8 +135,8 @@ function handleDownloadExcel() {
{{ $t('pages.common.delete') }}
@@ -152,8 +149,24 @@ function handleDownloadExcel() {
+
+ tableApi.query()"
+ />
+
+
+ {{ $t('pages.common.info') }}
+
+
diff --git a/apps/web-antd/src/views/property/assetManage/suppliers/suppliers-detail.vue b/apps/web-antd/src/views/property/assetManage/suppliers/suppliers-detail.vue
new file mode 100644
index 00000000..1be27e36
--- /dev/null
+++ b/apps/web-antd/src/views/property/assetManage/suppliers/suppliers-detail.vue
@@ -0,0 +1,77 @@
+
+
+
+
+
+
+ {{ supplierDetail.suppliersName }}
+
+
+ {{supplierDetail.user}}
+
+
+ {{supplierDetail.phone}}
+
+
+ {{ supplierDetail.location}}
+
+
+ {{ supplierDetail.bank}}
+
+
+ {{ supplierDetail.bankNumber}}
+
+
+
+
+
+ {{ supplierDetail.createTime}}
+
+
+ {{ supplierDetail.remark}}
+
+
+
+
diff --git a/apps/web-antd/src/views/property/suppliers/suppliers-modal.vue b/apps/web-antd/src/views/property/assetManage/suppliers/suppliers-modal.vue
similarity index 95%
rename from apps/web-antd/src/views/property/suppliers/suppliers-modal.vue
rename to apps/web-antd/src/views/property/assetManage/suppliers/suppliers-modal.vue
index 00c063a9..513fda8d 100644
--- a/apps/web-antd/src/views/property/suppliers/suppliers-modal.vue
+++ b/apps/web-antd/src/views/property/assetManage/suppliers/suppliers-modal.vue
@@ -6,7 +6,7 @@ import { $t } from '@vben/locales';
import { cloneDeep } from '@vben/utils';
import { useVbenForm } from '#/adapter/form';
-import { suppliersAdd, suppliersInfo, suppliersUpdate } from '#/api/property/suppliers';
+import { suppliersAdd, suppliersInfo, suppliersUpdate } from '#/api/property/assetManage/suppliers';
import { defaultFormValueGetter, useBeforeCloseDiff } from '#/utils/popup';
import { modalSchema } from './data';
@@ -21,9 +21,9 @@ const title = computed(() => {
const [BasicForm, formApi] = useVbenForm({
commonConfig: {
// 默认占满两列
- formItemClass: 'col-span-2',
+ formItemClass: 'col-span-1',
// 默认label宽度 px
- labelWidth: 80,
+ labelWidth: 100,
// 通用配置项 会影响到所有表单项
componentProps: {
class: 'w-full',
@@ -43,7 +43,7 @@ const { onBeforeClose, markInitialized, resetInitialized } = useBeforeCloseDiff(
const [BasicModal, modalApi] = useVbenModal({
// 在这里更改宽度
- class: 'w-[550px]',
+ class: 'w-[70%]',
fullscreenButton: false,
onBeforeClose,
onClosed: handleClosed,
diff --git a/apps/web-antd/src/views/property/depot/data.ts b/apps/web-antd/src/views/property/depot/data.ts
deleted file mode 100644
index b2d465ad..00000000
--- a/apps/web-antd/src/views/property/depot/data.ts
+++ /dev/null
@@ -1,95 +0,0 @@
-import type { FormSchemaGetter } from '#/adapter/form';
-import type { VxeGridProps } from '#/adapter/vxe-table';
-
-
-export const querySchema: FormSchemaGetter = () => [
- {
- component: 'Input',
- fieldName: 'depotName',
- label: '类型名称',
- },
- {
- component: 'Input',
- fieldName: 'msg',
- label: '描述信息',
- },
- {
- component: 'Input',
- fieldName: 'modelType',
- label: '类型',
- },
- {
- component: 'Input',
- fieldName: 'state',
- label: '状态',
- },
-];
-
-// 需要使用i18n注意这里要改成getter形式 否则切换语言不会刷新
-// export const columns: () => VxeGridProps['columns'] = () => [
-export const columns: VxeGridProps['columns'] = [
- { type: 'checkbox', width: 60 },
- {
- title: '主键',
- field: 'id',
- },
- {
- title: '类型名称',
- field: 'depotName',
- },
- {
- title: '描述信息',
- field: 'msg',
- },
- {
- title: '类型',
- field: 'modelType',
- },
- {
- title: '状态',
- field: 'state',
- },
- {
- title: '创建时间',
- field: 'createTime',
- },
- {
- 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: 'depotName',
- component: 'Input',
- },
- {
- label: '描述信息',
- fieldName: 'msg',
- component: 'Input',
- },
- {
- label: '类型',
- fieldName: 'modelType',
- component: 'Input',
- },
- {
- label: '状态',
- fieldName: 'state',
- component: 'Input',
- },
-];
diff --git a/apps/web-antd/src/views/property/resident/person/index.vue b/apps/web-antd/src/views/property/resident/person/index.vue
index fffc139b..85a93526 100644
--- a/apps/web-antd/src/views/property/resident/person/index.vue
+++ b/apps/web-antd/src/views/property/resident/person/index.vue
@@ -198,3 +198,8 @@ function handleInfo(row: Required) {
+
diff --git a/apps/web-antd/src/views/property/resident/person/person-modal.vue b/apps/web-antd/src/views/property/resident/person/person-modal.vue
index a28f2341..6f0ecdb8 100644
--- a/apps/web-antd/src/views/property/resident/person/person-modal.vue
+++ b/apps/web-antd/src/views/property/resident/person/person-modal.vue
@@ -26,6 +26,7 @@ let userInfo = reactive({
gender: '',
});
let unitName = ref('');
+const userId = ref(0);
const [BasicForm, formApi] = useVbenForm({
commonConfig: {
// 默认占满两列
@@ -67,6 +68,8 @@ const [BasicModal, modalApi] = useVbenModal({
if (isUpdate.value && id) {
const record = await personInfo(id);
+ userId.value = record.userId;
+ console.log(userId.value,'====================1111')
await formApi.setValues(record);
}
await markInitialized();
@@ -119,7 +122,7 @@ function getUnitInfo(unit: { name: string }) {
-
+
diff --git a/apps/web-antd/src/views/property/resident/person/query-unit-list.vue b/apps/web-antd/src/views/property/resident/person/query-unit-list.vue
index 19337d82..993c31bd 100644
--- a/apps/web-antd/src/views/property/resident/person/query-unit-list.vue
+++ b/apps/web-antd/src/views/property/resident/person/query-unit-list.vue
@@ -1,8 +1,7 @@
-
tableApi.query()"
/>