diff --git a/src/api/eam/basic/item/index.ts b/src/api/eam/basic/item/index.ts index f227cf4..f56e625 100644 --- a/src/api/eam/basic/item/index.ts +++ b/src/api/eam/basic/item/index.ts @@ -1,32 +1,32 @@ import request from '@/config/axios' export interface ItemVO { - number: string - name: string - brand: string - specifications: string - isConstant: string - subject: string - classification: string - uom: string - singlePrice: number - reprocurement: number - safetyStock: number - cost: string - purchaser: string - financer: string - isFramework: string - isRadeIn: string - siteId: string - available: string - concurrencyStamp: number + number : string + name : string + brand : string + specifications : string + isConstant : string + subject : string + classification : string + uom : string + singlePrice : number + reprocurement : number + safetyStock : number + cost : string + purchaser : string + financer : string + isFramework : string + isRadeIn : string + siteId : string + available : string + concurrencyStamp : number } // 查询备件列表 export const getItemPage = async (params) => { if (params.isSearch) { delete params.isSearch - const data = {...params} + const data = { ...params } return await request.post({ url: '/eam/item/senior', data }) } else { return await request.get({ url: `/eam/item/page`, params }) @@ -34,31 +34,31 @@ export const getItemPage = async (params) => { } // 生成标签 -export const genDevice = async (data: ItemVO) => { - return await request.post({ url: `/eam/item/genDevice`,data}) +export const genDevice = async (data) => { + return await request.post({ url: `/eam/item/genDevice`, data }) } // 查询备件详情 -export const getItem = async (id: number) => { +export const getItem = async (id : number) => { return await request.get({ url: `/eam/item/get?id=` + id }) } // 新增备件 -export const createItem = async (data: ItemVO) => { +export const createItem = async (data : ItemVO) => { return await request.post({ url: `/eam/item/create`, data }) } // 修改备件 -export const updateItem = async (data: ItemVO) => { +export const updateItem = async (data : ItemVO) => { return await request.put({ url: `/eam/item/update`, data }) } // 删除备件 -export const deleteItem = async (id: number) => { +export const deleteItem = async (id : number) => { return await request.delete({ url: `/eam/item/delete?id=` + id }) } // 导出备件 Excel export const exportItem = async (params) => { return await request.download({ url: `/eam/item/export-excel`, params }) -} +} \ No newline at end of file diff --git a/src/api/eam/basic/rel/index.ts b/src/api/eam/basic/rel/index.ts index 25f2620..6d36567 100644 --- a/src/api/eam/basic/rel/index.ts +++ b/src/api/eam/basic/rel/index.ts @@ -44,8 +44,7 @@ export const exportDeviceItem = async (params) => { return await request.download({ url: `/rel/device-item/export-excel`, params }) } -// 新增设备备件关系 // 新增设备备件关系 export const createDeviceItemBatch = async (data: Array) => { - return await request.post({url: `/rel/device-item/createBatch`, data }); + return await request.post({url: `/rel/device-item/createBatch `, data }); }; diff --git a/src/utils/dict.ts b/src/utils/dict.ts index e1b5b4f..60b2fe4 100644 --- a/src/utils/dict.ts +++ b/src/utils/dict.ts @@ -282,5 +282,7 @@ export enum DICT_TYPE { CLASS_TYPE = 'class_type', // 班组类型 INVENTORY_ACTION = 'inventory_action', //库存动作 MAINTENANCE_TYPE = 'maintenance_type', //保养类型 - JX_STATUS = 'JX_STATUS', //检修状态 -} \ No newline at end of file + JX_STATUS = 'JX_STATUS', //检修状态, + EXECUTION_CYCLE = 'execution_cycle', //模具保养周期 + MOLD_EXECUTION_CYCLE = 'mold_execution_cycle', //模具保养周期 +} diff --git a/src/utils/disposition/defaultButtons.ts b/src/utils/disposition/defaultButtons.ts index 3354de4..d387ee0 100644 --- a/src/utils/disposition/defaultButtons.ts +++ b/src/utils/disposition/defaultButtons.ts @@ -775,6 +775,19 @@ export function selectItemBtn(option:any) { }) } +// 主列表-备件选设备 +export function chooseDeviceBtn(option:any) { + return __defaultBtnOption(option,{ + label: '选择设备', + name: 'chooseDevice', + hide: false, + type: 'primary', + color: '', + link: true, // 文本展现按钮 + hasPermi: '' + }) +} + // 主列表-撤销 export function backoutBtn(option:any) { return __defaultBtnOption(option,{ diff --git a/src/views/eam/basic/deviceMaintenance/deviceMaintenance.data.ts b/src/views/eam/basic/deviceMaintenance/deviceMaintenance.data.ts index e7fef3c..b998313 100644 --- a/src/views/eam/basic/deviceMaintenance/deviceMaintenance.data.ts +++ b/src/views/eam/basic/deviceMaintenance/deviceMaintenance.data.ts @@ -37,7 +37,7 @@ export const DeviceMOLD = useCrudSchemas(reactive([ export const DeviceMaintenance = useCrudSchemas(reactive([ { - label: '保养项名称', + label: '保养内容', field: 'name', sort: 'custom', isSearch: true, @@ -114,6 +114,17 @@ export const DeviceMaintenance = useCrudSchemas(reactive([ } }, }, + { + label: '保养类型', + field: 'executionCycle', + dictType: DICT_TYPE.EXECUTION_CYCLE, + dictClass: 'string', + sort: 'custom', + isSearch: false, + form: { + component: 'Select' + }, + }, { label: '是否可用', field: 'available', diff --git a/src/views/eam/basic/inspection/deviceMoldItems.data.ts b/src/views/eam/basic/inspection/deviceMoldItems.data.ts index 6d41074..a241676 100644 --- a/src/views/eam/basic/inspection/deviceMoldItems.data.ts +++ b/src/views/eam/basic/inspection/deviceMoldItems.data.ts @@ -37,7 +37,7 @@ export const DeviceMOLD = useCrudSchemas(reactive([ export const DeviceMoldItems = useCrudSchemas(reactive([ { - label: '保养项名称', + label: '保养内容', field: 'name', sort: 'custom', isSearch: true, @@ -49,7 +49,7 @@ export const DeviceMoldItems = useCrudSchemas(reactive([ dictType: DICT_TYPE.DEVICE_MOLD_TYPE, dictClass: 'string', sort: 'custom', - isSearch: true, + isSearch: false, form: { component: 'Select' }, @@ -58,7 +58,7 @@ export const DeviceMoldItems = useCrudSchemas(reactive([ label: '设备/模具编号', field: 'deviceNumber', sort: 'custom', - isSearch: true, + isSearch: false, form: { // labelMessage: '信息提示说明!!!', componentProps: { @@ -88,7 +88,7 @@ export const DeviceMoldItems = useCrudSchemas(reactive([ dictType: DICT_TYPE.DEVICEMOLDITEMS_STATUS, dictClass: 'string', sort: 'custom', - isSearch: true, + isSearch: false, form: { component: 'Select', value: 'INSPECTION', @@ -97,12 +97,20 @@ export const DeviceMoldItems = useCrudSchemas(reactive([ } }, }, + + { + label: '设备部位', + field: 'equipmentParts', + sort: 'custom', + isSearch: true, + }, + { label: '是否可用', field: 'available', dictType: DICT_TYPE.TRUE_FALSE, dictClass: 'string', - isSearch: true, + isSearch: false, isTable: true, sort: 'custom', table: { diff --git a/src/views/eam/basic/item/index.vue b/src/views/eam/basic/item/index.vue index 372b250..3cebf94 100644 --- a/src/views/eam/basic/item/index.vue +++ b/src/views/eam/basic/item/index.vue @@ -30,18 +30,18 @@ :apiUpdate="ItemApi.updateItem" :apiCreate="ItemApi.createItem" @searchTableSuccess="searchTableSuccess" :isBusiness="false" /> + + - - + \ No newline at end of file diff --git a/src/views/eam/basic/moldMaintenance/moldMaintenance.data.ts b/src/views/eam/basic/moldMaintenance/moldMaintenance.data.ts index 4a7967a..e53eb78 100644 --- a/src/views/eam/basic/moldMaintenance/moldMaintenance.data.ts +++ b/src/views/eam/basic/moldMaintenance/moldMaintenance.data.ts @@ -37,7 +37,7 @@ export const DeviceMOLD = useCrudSchemas(reactive([ export const MoldMaintenance = useCrudSchemas(reactive([ { - label: '保养项名称', + label: '保养内容', field: 'name', sort: 'custom', isSearch: true, @@ -110,6 +110,18 @@ export const MoldMaintenance = useCrudSchemas(reactive([ component: 'Select' }, }, + + { + label: '保养周期', + field: 'executionCycle', + dictType: DICT_TYPE.MOLD_EXECUTION_CYCLE, + dictClass: 'string', + sort: 'custom', + isSearch: false, + form: { + component: 'Select' + }, + }, { label: '是否可用', field: 'available',