diff --git a/src/views/eam/basic/item/item.data.ts b/src/views/eam/basic/item/item.data.ts index 9cfcd4b..2b5ee0c 100644 --- a/src/views/eam/basic/item/item.data.ts +++ b/src/views/eam/basic/item/item.data.ts @@ -3,23 +3,13 @@ import { dateFormatter } from '@/utils/formatTime' // 表单校验 export const ItemRules = reactive({ - name: [ - { required: true, message: '请输入备件名称', trigger: 'blur' }, + number: [ + { required: true, message: '请输入备件编号', trigger: 'blur' }, { max: 50, message: '不得超过50个字符', trigger: 'blur' } ], uom: [ - { required: true, message: '请选择备件单位', trigger: 'blur' }, { max: 50, message: '不得超过50个字符', trigger: 'blur' } ], - maxInventory: [ - { required: true, message: '请输入最高库存', trigger: 'blur' } - ], - minInventory: [ - { required: true, message: '请输入最高库存', trigger: 'blur' } - ], - classification: [ - { required: true, message: '请输入ABC分类', trigger: 'blur' } - ], }) export const ItemSearchTable = useCrudSchemas(reactive([ @@ -49,7 +39,7 @@ export const ItemSearchTable = useCrudSchemas(reactive([ ])) export const Item = useCrudSchemas(reactive([ { - label: '零件编码', + label: '备件编码', field: 'number', sort: 'custom', isSearch: true, @@ -59,7 +49,7 @@ export const Item = useCrudSchemas(reactive([ }, }, { - label: '零件名称', + label: '备件名称', field: 'name', sort: 'custom', isSearch: true, @@ -175,10 +165,21 @@ export const Item = useCrudSchemas(reactive([ label: '价格', field: 'price', sort: 'custom', - isSearch: false, table: { - width: 110 + width: 150 }, + form: { + component: 'InputNumber', + componentProps: { + min: 1, + precision: 6 + } + }, + tableForm: { + type: 'InputNumber', + min: 1, + precision: 6 + } }, { label: '描述', diff --git a/src/views/eam/basic/location/location.data.ts b/src/views/eam/basic/location/location.data.ts index 124981b..3660ec4 100644 --- a/src/views/eam/basic/location/location.data.ts +++ b/src/views/eam/basic/location/location.data.ts @@ -6,18 +6,17 @@ import { LocationArea } from '../locationArea/locationArea.data' // 表单校验 export const LocationRules = reactive({ - number: [ - { required: true, message: '请输入库位编号', trigger: 'blur' }, - { max: 50, message: '不得超过50个字符', trigger: 'blur' } - ], + number: [ + { required: true, message: '请输入库位编号', trigger: 'blur' }, + { max: 50, message: '不得超过50个字符', trigger: 'blur' } + ], name: [ - { required: true, message: '请输入库位名称', trigger: 'blur' }, { max: 50, message: '不得超过50个字符', trigger: 'blur' } ], areaNumber: [ - { required: true, message: '请选择库区编号', trigger: 'blur' }, + { required: true, message: '请选择库区编号', trigger: 'blur' }, ], - + }) export const Location = useCrudSchemas(reactive([ @@ -43,6 +42,23 @@ export const Location = useCrudSchemas(reactive([ field: 'areaNumber', sort: 'custom', isSearch: true, + form: { + // labelMessage: '信息提示说明!!!', + componentProps: { + isSearchList: true, // 开启查询弹窗 + searchListPlaceholder: '请选择库区编号', // 输入框占位文本 + searchField: 'number', // 查询弹窗赋值字段 + searchTitle: '库区信息', // 查询弹窗标题 + searchAllSchemas: LocationArea.allSchemas, // 查询弹窗所需类 + searchPage: LocationAreaApi.getLocationAreaPage, // 查询弹窗所需分页方法 + searchCondition: [ + { + key: 'available', + value: "TRUE", + isMainValue: false + }] + } + } }, { label: '创建时间', @@ -50,9 +66,9 @@ export const Location = useCrudSchemas(reactive([ sort: 'custom', formatter: dateFormatter, isForm: false, - table: { - width: 170 - }, + table: { + width: 170 + }, }, { label: '描述', diff --git a/src/views/eam/basic/locationArea/locationArea.data.ts b/src/views/eam/basic/locationArea/locationArea.data.ts index c7524f4..7789f42 100644 --- a/src/views/eam/basic/locationArea/locationArea.data.ts +++ b/src/views/eam/basic/locationArea/locationArea.data.ts @@ -8,7 +8,6 @@ export const LocationAreaRules = reactive({ { max: 50, message: '不得超过50个字符', trigger: 'blur' } ], name: [ - { required: true, message: '请输入库区名称', trigger: 'blur' }, { max: 50, message: '不得超过50个字符', trigger: 'blur' } ], }) diff --git a/src/views/eam/item/itemAccounts/itemAccounts.data.ts b/src/views/eam/item/itemAccounts/itemAccounts.data.ts index 476b892..2640cc8 100644 --- a/src/views/eam/item/itemAccounts/itemAccounts.data.ts +++ b/src/views/eam/item/itemAccounts/itemAccounts.data.ts @@ -135,21 +135,6 @@ export const ItemAccounts = useCrudSchemas( width: 130 }, }, - // { - // label: '库位类型', - // field: 'type', - // dictType: DICT_TYPE.ITEM_ACCOUNT_LOCATION_TYPE, - // dictClass: 'string', - // isSearch: true, - // isTable: true, - // sort: 'custom', - // table: { - // width: 130 - // }, - // form: { - // component: 'Select' - // } - // }, { label: '库区类型', field: 'type', @@ -188,21 +173,6 @@ export const ItemAccounts = useCrudSchemas( } }, }, - // { - // label: '库位类型', - // field: 'type', - // dictType: DICT_TYPE.ITEM_ACCOUNT_LOCATION_TYPE, - // dictClass: 'string', - // isSearch: true, - // isTable: true, - // sort: 'custom', - // table: { - // width: 130 - // }, - // form: { - // component: 'Select' - // } - // }, { label: '库存数量', field: 'qty', @@ -218,6 +188,53 @@ export const ItemAccounts = useCrudSchemas( } } }, + { + label: '单位', + field: 'uom', + sort: 'custom', + isSearch: false, + table: { + width: 110 + }, + }, + { + label: '规格型号', + field: 'specifications', + sort: 'custom', + isSearch: false, + table: { + width: 110 + }, + }, + { + label: 'ABC分类', + field: 'classification', + sort: 'custom', + dictType: DICT_TYPE.CLASSIFICATION, + dictClass: 'string', + isTable: true, + table: { + width: 100 + } , + }, + { + label: '使用地点', + field: 'usePlace', + sort: 'custom', + isSearch: false, + table: { + width: 110 + }, + }, + { + label: '项目', + field: 'project', + sort: 'custom', + isSearch: false, + table: { + width: 110 + }, + }, { label: '创建时间', field: 'createTime',