From 5eac7000602965da71be547c394baa4d69803aed Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E6=B7=BB=E7=A0=96-JAVA=5CAdministrator?= <591141169@qq.com> Date: Thu, 29 Feb 2024 13:24:52 +0800 Subject: [PATCH] =?UTF-8?q?BUG=E4=BF=AE=E6=94=B9?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../deviceMaintenance.data.ts | 30 ++++- src/views/eam/basic/item/item.data.ts | 13 +- src/views/eam/basic/location/location.data.ts | 20 +-- .../basic/locationArea/locationArea.data.ts | 7 +- src/views/eam/basic/supplier/supplier.data.ts | 14 +- .../item/itemAccounts/itemAccounts.data.ts | 3 - .../item/itemOrderMain/itemOrderMain.data.ts | 125 ++++++++++++++++-- 7 files changed, 174 insertions(+), 38 deletions(-) diff --git a/src/views/eam/basic/deviceMaintenance/deviceMaintenance.data.ts b/src/views/eam/basic/deviceMaintenance/deviceMaintenance.data.ts index 26b0201..07e6783 100644 --- a/src/views/eam/basic/deviceMaintenance/deviceMaintenance.data.ts +++ b/src/views/eam/basic/deviceMaintenance/deviceMaintenance.data.ts @@ -100,7 +100,7 @@ export const DeviceMaintenance = useCrudSchemas(reactive([ }, }, { - label: '保养类型', + label: '保养周期', field: 'executionCycle', dictType: DICT_TYPE.EXECUTION_CYCLE, dictClass: 'string', @@ -110,6 +110,32 @@ export const DeviceMaintenance = useCrudSchemas(reactive([ component: 'Select' }, }, + + { + label: '人数', + field: 'peopleNum', + sort: 'custom', + isSearch: false, + table: { + width: 150, + }, + form: { + component: 'InputNumber', + } + }, + { + label: '保养所需时间(h)', + field: 'maintenanceTime', + sort: 'custom', + isSearch: false, + table: { + width: 150, + }, + form: { + component: 'InputNumber', + } + }, + { label: '是否可用', field: 'available', @@ -144,4 +170,4 @@ export const DeviceMaintenance = useCrudSchemas(reactive([ fixed: 'right' } } -])) \ No newline at end of file +])) diff --git a/src/views/eam/basic/item/item.data.ts b/src/views/eam/basic/item/item.data.ts index 4800dba..8605ab2 100644 --- a/src/views/eam/basic/item/item.data.ts +++ b/src/views/eam/basic/item/item.data.ts @@ -2,10 +2,10 @@ import type { CrudSchema } from '@/hooks/web/useCrudSchemas' // 表单校验 export const ItemRules = reactive({ - number: [required], - name: [required], - uom: [required], - concurrencyStamp: [required], + name: [ + { required: true, message: '请输入备件名称', trigger: 'blur' }, + { max: 50, message: '不得超过50个字符', trigger: 'blur' } + ], }) export const Item = useCrudSchemas(reactive([ @@ -188,6 +188,11 @@ export const Item = useCrudSchemas(reactive([ } } }, + { + label: '描述', + field: 'describes', + sort: 'custom', + }, { label: '操作', field: 'action', diff --git a/src/views/eam/basic/location/location.data.ts b/src/views/eam/basic/location/location.data.ts index aa480c6..868c683 100644 --- a/src/views/eam/basic/location/location.data.ts +++ b/src/views/eam/basic/location/location.data.ts @@ -5,10 +5,14 @@ import { LocationArea } from '../locationArea/locationArea.data' // 表单校验 export const LocationRules = reactive({ - number: [required], - name: [required], - areaNumber: [required], - concurrencyStamp: [required], + name: [ + { required: true, message: '请输入库位名称', trigger: 'blur' }, + { max: 50, message: '不得超过50个字符', trigger: 'blur' } + ], + areaNumber: [ + { required: true, message: '请选择库区编号', trigger: 'blur' }, + ], + }) export const Location = useCrudSchemas(reactive([ @@ -58,7 +62,7 @@ export const Location = useCrudSchemas(reactive([ dictType: DICT_TYPE.LOCATION_AREA_TYPE, dictClass: 'string', sort: 'custom', - isSearch: true, + isSearch: false, form: { component: 'Select' }, @@ -68,7 +72,7 @@ export const Location = useCrudSchemas(reactive([ field: 'isInAccount', dictType: DICT_TYPE.TRUE_FALSE, dictClass: 'string', - isSearch: true, + isSearch: false, isTable: true, sort: 'custom', table: { @@ -93,7 +97,7 @@ export const Location = useCrudSchemas(reactive([ field: 'available', dictType: DICT_TYPE.TRUE_FALSE, dictClass: 'string', - isSearch: true, + isSearch: false, isTable: true, sort: 'custom', table: { @@ -130,4 +134,4 @@ export const Location = useCrudSchemas(reactive([ fixed: 'right' } } -])) \ No newline at end of file +])) diff --git a/src/views/eam/basic/locationArea/locationArea.data.ts b/src/views/eam/basic/locationArea/locationArea.data.ts index 151e3ca..06d5688 100644 --- a/src/views/eam/basic/locationArea/locationArea.data.ts +++ b/src/views/eam/basic/locationArea/locationArea.data.ts @@ -3,9 +3,10 @@ import { dateFormatter } from '@/utils/formatTime' // 表单校验 export const LocationAreaRules = reactive({ - number: [required], - name: [required], - concurrencyStamp: [required], + name: [ + { required: true, message: '请输入库区名称', trigger: 'blur' }, + { max: 50, message: '不得超过50个字符', trigger: 'blur' } + ], }) export const LocationArea = useCrudSchemas(reactive([ diff --git a/src/views/eam/basic/supplier/supplier.data.ts b/src/views/eam/basic/supplier/supplier.data.ts index 07e75d1..94a12e6 100644 --- a/src/views/eam/basic/supplier/supplier.data.ts +++ b/src/views/eam/basic/supplier/supplier.data.ts @@ -2,8 +2,10 @@ import type { CrudSchema } from '@/hooks/web/useCrudSchemas' // 表单校验 export const SupplierRules = reactive({ - number: [required], - name: [required], + name: [ + { required: true, message: '请输入供应商名称', trigger: 'blur' }, + { max: 50, message: '不得超过50个字符', trigger: 'blur' } + ], }) export const Supplier = useCrudSchemas(reactive([ @@ -28,7 +30,7 @@ export const Supplier = useCrudSchemas(reactive([ label: '简称', field: 'shortName', sort: 'custom', - isSearch: true, + isSearch: false, }, { label: '联系人', @@ -39,14 +41,14 @@ export const Supplier = useCrudSchemas(reactive([ label: '联系电话', field: 'phone', sort: 'custom', - isSearch: true, + isSearch: false, }, { label: '状态', field: 'available', dictType: DICT_TYPE.TRUE_FALSE, dictClass: 'string', - isSearch: true, + isSearch: false, isTable: true, sort: 'custom', table: { @@ -80,4 +82,4 @@ export const Supplier = useCrudSchemas(reactive([ fixed: 'right' } } -])) \ No newline at end of file +])) diff --git a/src/views/eam/item/itemAccounts/itemAccounts.data.ts b/src/views/eam/item/itemAccounts/itemAccounts.data.ts index 9db54bc..9198994 100644 --- a/src/views/eam/item/itemAccounts/itemAccounts.data.ts +++ b/src/views/eam/item/itemAccounts/itemAccounts.data.ts @@ -88,7 +88,6 @@ export const ItemAccounts = useCrudSchemas(reactive([ field: 'itemDO.isConstant', dictType: DICT_TYPE.TRUE_FALSE, dictClass: 'string', - isSearch: true, isTable: true, sort: 'custom', table: { @@ -119,7 +118,6 @@ export const ItemAccounts = useCrudSchemas(reactive([ sort: 'custom', dictType: DICT_TYPE.UOM, dictClass: 'string', - isSearch: true, isTable: true, table: { width: 150 @@ -171,7 +169,6 @@ export const ItemAccounts = useCrudSchemas(reactive([ field: 'itemDO.isRadeIn', dictType: DICT_TYPE.TRUE_FALSE, dictClass: 'string', - isSearch: true, isTable: true, sort: 'custom', table: { diff --git a/src/views/eam/item/itemOrderMain/itemOrderMain.data.ts b/src/views/eam/item/itemOrderMain/itemOrderMain.data.ts index f59acc1..4efb684 100644 --- a/src/views/eam/item/itemOrderMain/itemOrderMain.data.ts +++ b/src/views/eam/item/itemOrderMain/itemOrderMain.data.ts @@ -16,30 +16,125 @@ export const ItemOrderMain = useCrudSchemas(reactive([ isForm: false, isSearch: true, table: { - width: 180, + width: 150, fixed: 'left' }, }, { - label: '申领人', - field: 'applyId', + label: '日期', + field: 'date', sort: 'custom', - isForm: false, - isSearch: false, + formatter: dateFormatter, + form: { + component: 'DatePicker', + componentProps: { + type: 'datetime', + valueFormat: 'x' + } + }, }, { - label: '审批人', - field: 'approveId', + label: '电话', + field: 'phone', sort: 'custom', - isForm: false, - isSearch: false, }, { - label: '出库人', - field: 'outId', + label: '传真', + field: 'fax', sort: 'custom', - isForm: false, + }, + { + label: '采购员', + field: 'purchaser', + sort: 'custom', + }, + { + label: '供应商编号', + field: 'supplierNumber', + sort: 'custom', + }, + { + label: '供应商名称', + field: 'supplierName', + sort: 'custom', + }, + { + label: '供应商地址', + field: 'supplierAddress', + sort: 'custom', + }, + { + label: '发货至', + field: 'shipTo', + sort: 'custom', + }, + { + label: '开票至', + field: 'invoiceTo', + sort: 'custom', + }, + { + label: '联系人', + field: 'contacts', + sort: 'custom', + }, + { + label: '联系电话', + field: 'contactsPhone', + sort: 'custom', + }, + { + label: '付款方式', + field: 'paymentType', + sort: 'custom', + form: { + component: 'Select' + }, + }, + { + label: '注册地', + field: 'registLocation', + sort: 'custom', + }, + { + label: '开户行', + field: 'bank', + sort: 'custom', + }, + { + label: '账号', + field: 'account', + sort: 'custom', + }, + { + label: '税号', + field: 'dutyParagraph', + sort: 'custom', + }, + { + label: '是否关闭', + field: 'available', + dictType: DICT_TYPE.TRUE_FALSE, + dictClass: 'string', isSearch: false, + isTable: true, + sort: 'custom', + table: { + width: 150 + }, + tableForm: { + type: 'Select', + inactiveValue: 'FALSE', + disabled: true + }, + form: { + component: 'Switch', + value: 'FALSE', + componentProps: { + inactiveValue: 'FALSE', + activeValue: 'TRUE' + } + } }, { label: '状态', @@ -51,6 +146,12 @@ export const ItemOrderMain = useCrudSchemas(reactive([ isForm: true, tableForm: { type: 'Select' + }, + form: { + value: 'INCOMPLETE', + componentProps: { + disabled: true, + } } }, {