diff --git a/src/api/eam/basic/deviceMaintenance/index.ts b/src/api/eam/basic/deviceMaintenance/index.ts index 1fac84d..2b4a946 100644 --- a/src/api/eam/basic/deviceMaintenance/index.ts +++ b/src/api/eam/basic/deviceMaintenance/index.ts @@ -13,6 +13,7 @@ export interface DeviceMoldItemsVO { // 查询项记录表(设备 模具 保养 维修 巡检点检)列表 export const getDeviceMoldItemsPage = async (params) => { params.type="DEVICE" + params.status="MAINTAIN" if (params.isSearch) { delete params.isSearch const data = {...params} @@ -35,11 +36,15 @@ export const getNumber = async (params) => { // 新增项记录表(设备 模具 保养 维修 巡检点检) export const createDeviceMoldItems = async (data: DeviceMoldItemsVO) => { + data.type="DEVICE" + data.status="MAINTAIN" return await request.post({ url: `/eam/device-mold-items/create`, data }) } // 修改项记录表(设备 模具 保养 维修 巡检点检) export const updateDeviceMoldItems = async (data: DeviceMoldItemsVO) => { + data.type="DEVICE" + data.status="MAINTAIN" return await request.put({ url: `/eam/device-mold-items/update`, data }) } diff --git a/src/api/eam/basic/inspection/index.ts b/src/api/eam/basic/inspection/index.ts new file mode 100644 index 0000000..c1eaafb --- /dev/null +++ b/src/api/eam/basic/inspection/index.ts @@ -0,0 +1,61 @@ +import request from '@/config/axios' + +export interface DeviceMoldItemsVO { + name: string + deviceNumber: string + type: "DEVICE" + status: string + siteId: string + available: string + concurrencyStamp: number +} + +// 查询项记录表(设备 模具 保养 维修 巡检点检)列表 +export const getDeviceMoldItemsPage = async (params) => { + params.type="DEVICE" + params.status="INSPECTION" + if (params.isSearch) { + delete params.isSearch + const data = {...params} + return await request.post({ url: '/eam/device-mold-items/senior', data }) + } else { + return await request.get({ url: `/eam/device-mold-items/page`, params }) + } +} + + +// 查询项记录表(设备 模具 保养 维修 巡检点检)详情 +export const getDeviceMoldItems = async (id: number) => { + return await request.get({ url: `/eam/device-mold-items/get?id=` + id }) +} + +// 查询供应商发票申请主详情 +export const getNumber = async (params) => { + return await request.get({ url: `/eam/device-mold-items/getNumber`, params}) +} + +// 新增项记录表(设备 模具 保养 维修 巡检点检) +export const createDeviceMoldItems = async (data: DeviceMoldItemsVO) => { + data.type="DEVICE" + data.status="INSPECTION" + return await request.post({ url: `/eam/device-mold-items/create`, data }) +} + +// 修改项记录表(设备 模具 保养 维修 巡检点检) +export const updateDeviceMoldItems = async (data: DeviceMoldItemsVO) => { + data.type="DEVICE" + data.status="INSPECTION" + return await request.put({ url: `/eam/device-mold-items/update`, data }) +} + +// 删除项记录表(设备 模具 保养 维修 巡检点检) +export const deleteDeviceMoldItems = async (id: number) => { + return await request.delete({ url: `/eam/device-mold-items/delete?id=` + id }) +} + +// 导出项记录表(设备 模具 保养 维修 巡检点检) Excel +export const exportDeviceMoldItems = async (params) => { + return await request.download({ url: `/eam/device-mold-items/export-excel`, params }) +} + + diff --git a/src/api/eam/basic/moldMaintenance/index.ts b/src/api/eam/basic/moldMaintenance/index.ts index 4081838..058610a 100644 --- a/src/api/eam/basic/moldMaintenance/index.ts +++ b/src/api/eam/basic/moldMaintenance/index.ts @@ -13,6 +13,7 @@ export interface DeviceMoldItemsVO { // 查询项记录表(设备 模具 保养 维修 巡检点检)列表 export const getDeviceMoldItemsPage = async (params) => { params.type="MOLD" + params.status="MAINTAIN" if (params.isSearch) { delete params.isSearch const data = {...params} @@ -35,11 +36,15 @@ export const getNumber = async (params) => { // 新增项记录表(设备 模具 保养 维修 巡检点检) export const createDeviceMoldItems = async (data: DeviceMoldItemsVO) => { + data.type="MOLD" + data.status="MAINTAIN" return await request.post({ url: `/eam/device-mold-items/create`, data }) } // 修改项记录表(设备 模具 保养 维修 巡检点检) export const updateDeviceMoldItems = async (data: DeviceMoldItemsVO) => { + data.type="MOLD" + data.status="MAINTAIN" return await request.put({ url: `/eam/device-mold-items/update`, data }) } diff --git a/src/api/eam/item/applicationRecordDetail/index.ts b/src/api/eam/item/applicationRecordDetail/index.ts index 7d1ed1a..9a45b46 100644 --- a/src/api/eam/item/applicationRecordDetail/index.ts +++ b/src/api/eam/item/applicationRecordDetail/index.ts @@ -20,38 +20,38 @@ export const getApplicationRecordDetailPage = async (params) => { if (params.isSearch) { delete params.isSearch const data = { ...params } - return await request.post({ url: '/eam/item-apply-detail/senior', data }) + return await request.post({ url: '/eam/item-apply-request-detail/senior', data }) } else { - return await request.get({ url: `/eam/item-apply-detail/page`, params }) + return await request.get({ url: `/eam/item-apply-request-detail/page`, params }) } } // 查询备件申领记录主详情 export const getApplicationRecordDetail = async (id : number) => { - return await request.get({ url: `/eam/item-apply-detail/get?id=` + id }) + return await request.get({ url: `/eam/item-apply-request-detail/get?id=` + id }) } // 新增备件申领记录主 export const createApplicationRecordDetail = async (data : ItemApplyDetailVO) => { - return await request.post({ url: `/eam/item-apply-detail/create`, data }) + return await request.post({ url: `/eam/item-apply-request-detail/create`, data }) } // 修改备件申领记录主 export const updateApplicationRecordDetail = async (data : ItemApplyDetailVO) => { - return await request.put({ url: `/eam/item-apply-detail/update`, data }) + return await request.put({ url: `/eam/item-apply-request-detail/update`, data }) } // 删除备件申领记录主 export const deleteApplicationRecordDetail = async (id : number) => { - return await request.delete({ url: `/eam/item-apply-detail/delete?id=` + id }) + return await request.delete({ url: `/eam/item-apply-request-detail/delete?id=` + id }) } // 导出备件申领记录主 Excel export const exportApplicationRecordDetail = async (params) => { - return await request.download({ url: `/eam/item-apply-detail/export-excel`, params }) + return await request.download({ url: `/eam/item-apply-request-detail/export-excel`, params }) } // 下载用户导入模板 export const importTemplate = () => { - return request.download({ url: '/eam/item-apply-detail/get-import-template' }) -} \ No newline at end of file + return request.download({ url: '/eam/item-apply-request-detail/get-import-template' }) +} diff --git a/src/api/eam/item/itemAccounts/index.ts b/src/api/eam/item/itemAccounts/index.ts index f660e47..e3e5524 100644 --- a/src/api/eam/item/itemAccounts/index.ts +++ b/src/api/eam/item/itemAccounts/index.ts @@ -49,4 +49,9 @@ export const exportItemAccounts = async (params) => { // 下载用户导入模板 export const importTemplate = () => { return request.download({ url: '/eam/item-accounts/get-import-template' }) -} \ No newline at end of file +} + +// 更改备件库位 +export const replaceLocation = async (data: Array) => { + return await request.post({url: `/eam/item-accounts/replaceLocation `, data }); +}; diff --git a/src/api/eam/item/itemApplyDetail/index.ts b/src/api/eam/item/itemApplyDetail/index.ts index 0e5a01c..0941c11 100644 --- a/src/api/eam/item/itemApplyDetail/index.ts +++ b/src/api/eam/item/itemApplyDetail/index.ts @@ -20,38 +20,38 @@ export const getItemApplyDetailPage = async (params) => { if (params.isSearch) { delete params.isSearch const data = {...params} - return await request.post({ url: '/eam/item-apply-detail/senior', data }) + return await request.post({ url: '/eam/item-apply-request-detail/senior', data }) } else { - return await request.get({ url: `/eam/item-apply-detail/page`, params }) + return await request.get({ url: `/eam/item-apply-request-detail/page`, params }) } } // 查询备件申领记录主详情 export const getItemApplyDetail = async (id: number) => { - return await request.get({ url: `/eam/item-apply-detail/get?id=` + id }) + return await request.get({ url: `/eam/item-apply-request-detail/get?id=` + id }) } // 新增备件申领记录主 export const createItemApplyDetail = async (data: ItemApplyDetailVO) => { - return await request.post({ url: `/eam/item-apply-detail/create`, data }) + return await request.post({ url: `/eam/item-apply-request-detail/create`, data }) } // 修改备件申领记录主 export const updateItemApplyDetail = async (data: ItemApplyDetailVO) => { - return await request.put({ url: `/eam/item-apply-detail/update`, data }) + return await request.put({ url: `/eam/item-apply-request-detail/update`, data }) } // 删除备件申领记录主 export const deleteItemApplyDetail = async (id: number) => { - return await request.delete({ url: `/eam/item-apply-detail/delete?id=` + id }) + return await request.delete({ url: `/eam/item-apply-request-detail/delete?id=` + id }) } // 导出备件申领记录主 Excel export const exportItemApplyDetail = async (params) => { - return await request.download({ url: `/eam/item-apply-detail/export-excel`, params }) + return await request.download({ url: `/eam/item-apply-request-detail/export-excel`, params }) } // 下载用户导入模板 export const importTemplate = () => { - return request.download({ url: '/eam/item-apply-detail/get-import-template' }) + return request.download({ url: '/eam/item-apply-request-detail/get-import-template' }) } diff --git a/src/api/eam/item/itemLocationReplace/index.ts b/src/api/eam/item/itemLocationReplace/index.ts new file mode 100644 index 0000000..7bdab64 --- /dev/null +++ b/src/api/eam/item/itemLocationReplace/index.ts @@ -0,0 +1,49 @@ +import request from '@/config/axios' + +export interface ItemLocationReplaceVO { + locationNumber: string + describe: string + oldItemNumber: string + itemNumber: string +} + +// 查询备件库位变更记录列表 +export const getItemLocationReplacePage = async (params) => { + if (params.isSearch) { + delete params.isSearch + const data = {...params} + return await request.post({ url: '/eam/item-location-replace/senior', data }) + } else { + return await request.get({ url: `/eam/item-location-replace/page`, params }) + } +} + +// 查询备件库位变更记录详情 +export const getItemLocationReplace = async (id: number) => { + return await request.get({ url: `/eam/item-location-replace/get?id=` + id }) +} + +// 新增备件库位变更记录 +export const createItemLocationReplace = async (data: ItemLocationReplaceVO) => { + return await request.post({ url: `/eam/item-location-replace/create`, data }) +} + +// 修改备件库位变更记录 +export const updateItemLocationReplace = async (data: ItemLocationReplaceVO) => { + return await request.put({ url: `/eam/item-location-replace/update`, data }) +} + +// 删除备件库位变更记录 +export const deleteItemLocationReplace = async (id: number) => { + return await request.delete({ url: `/eam/item-location-replace/delete?id=` + id }) +} + +// 导出备件库位变更记录 Excel +export const exportItemLocationReplace = async (params) => { + return await request.download({ url: `/eam/item-location-replace/export-excel`, params }) +} + +// 下载用户导入模板 +export const importTemplate = () => { + return request.download({ url: '/eam/item-location-replace/get-import-template' }) +} diff --git a/src/views/eam/basic/deviceMaintenance/deviceMaintenance.data.ts b/src/views/eam/basic/deviceMaintenance/deviceMaintenance.data.ts index 07e6783..b3498da 100644 --- a/src/views/eam/basic/deviceMaintenance/deviceMaintenance.data.ts +++ b/src/views/eam/basic/deviceMaintenance/deviceMaintenance.data.ts @@ -113,7 +113,7 @@ export const DeviceMaintenance = useCrudSchemas(reactive([ { label: '人数', - field: 'peopleNum', + field: 'peoples', sort: 'custom', isSearch: false, table: { @@ -125,7 +125,7 @@ export const DeviceMaintenance = useCrudSchemas(reactive([ }, { label: '保养所需时间(h)', - field: 'maintenanceTime', + field: 'estimatedMinutes', sort: 'custom', isSearch: false, table: { diff --git a/src/views/eam/basic/inspection/index.vue b/src/views/eam/basic/inspection/index.vue index fdf55b1..0aa208a 100644 --- a/src/views/eam/basic/inspection/index.vue +++ b/src/views/eam/basic/inspection/index.vue @@ -57,8 +57,8 @@ diff --git a/src/views/eam/item/itemLocationReplace/itemLocationReplace.data.ts b/src/views/eam/item/itemLocationReplace/itemLocationReplace.data.ts new file mode 100644 index 0000000..bebf9b7 --- /dev/null +++ b/src/views/eam/item/itemLocationReplace/itemLocationReplace.data.ts @@ -0,0 +1,62 @@ +import type { CrudSchema } from '@/hooks/web/useCrudSchemas' +import { dateFormatter } from '@/utils/formatTime' + +// 表单校验 +export const ItemLocationReplaceRules = reactive({ + locationNumber: [required], + oldItemNumber: [required], + itemNumber: [required], +}) + +export const ItemLocationReplace = useCrudSchemas(reactive([ + { + label: '库位编号', + field: 'locationNumber', + sort: 'custom', + isSearch: true, + }, + + { + label: '变更前备件编号', + field: 'oldItemNumber', + sort: 'custom', + isSearch: true, + }, + { + label: '变更后备件编号', + field: 'itemNumber', + sort: 'custom', + isSearch: true, + }, + { + label: '创建时间', + field: 'createTime', + sort: 'custom', + formatter: dateFormatter, + isSearch: false, + search: { + component: 'DatePicker', + componentProps: { + valueFormat: 'YYYY-MM-DD HH:mm:ss', + type: 'daterange', + defaultTime: [new Date('1 00:00:00'), new Date('1 23:59:59')] + } + }, + isForm: false, + }, + { + label: '描述', + field: 'describe', + sort: 'custom', + isSearch: false, + }, + { + label: '操作', + field: 'action', + isForm: false, + table: { + width: 150, + fixed: 'right' + } + } +])) diff --git a/src/views/eam/item/itemOrderMain/itemOrderMain.data.ts b/src/views/eam/item/itemOrderMain/itemOrderMain.data.ts index 4efb684..3db0261 100644 --- a/src/views/eam/item/itemOrderMain/itemOrderMain.data.ts +++ b/src/views/eam/item/itemOrderMain/itemOrderMain.data.ts @@ -20,6 +20,19 @@ export const ItemOrderMain = useCrudSchemas(reactive([ fixed: 'left' }, }, + // { + // label: '日期', + // field: 'date', + // sort: 'custom', + // formatter: dateFormatter, + // form: { + // component: 'DatePicker', + // componentProps: { + // type: 'datetime', + // valueFormat: 'x' + // } + // }, + // }, { label: '日期', field: 'date', @@ -28,10 +41,13 @@ export const ItemOrderMain = useCrudSchemas(reactive([ form: { component: 'DatePicker', componentProps: { - type: 'datetime', + type: 'date', valueFormat: 'x' } }, + detail: { + dateFormat: 'YYYY-MM-DD' + } }, { label: '电话', @@ -111,7 +127,7 @@ export const ItemOrderMain = useCrudSchemas(reactive([ field: 'dutyParagraph', sort: 'custom', }, - { + { label: '是否关闭', field: 'available', dictType: DICT_TYPE.TRUE_FALSE, @@ -149,9 +165,9 @@ export const ItemOrderMain = useCrudSchemas(reactive([ }, form: { value: 'INCOMPLETE', - componentProps: { - disabled: true, - } + componentProps: { + disabled: true, + } } }, {