diff --git a/src/api/erp/stock/warehouse/index.ts b/src/api/erp/stock/warehouse/index.ts index 114cfa00..b953eeb2 100644 --- a/src/api/erp/stock/warehouse/index.ts +++ b/src/api/erp/stock/warehouse/index.ts @@ -13,6 +13,32 @@ export interface WarehouseVO { status: number // 开启状态 defaultStatus: boolean // 是否默认 warehouseId:number + areaList?: Array<{ + id: number + warehouseId: number + areaCode: string + areaName: string + areaSize: number + description: string + status: number + createTime: number + }> + locationList?: Array<{ + id: number + warehouseId: number + areaId: number + code: string + name: string + areaSize: number + maxLoadWeight: number + positionX: number + positionY: number + positionZ: number + allowProductMix: boolean + allowBatchMix: boolean + status: number + createTime: number + }> } // ERP 仓库 API diff --git a/src/api/erp/stock/warehousearea/index.ts b/src/api/erp/stock/warehousearea/index.ts new file mode 100644 index 00000000..5d0b9296 --- /dev/null +++ b/src/api/erp/stock/warehousearea/index.ts @@ -0,0 +1,34 @@ +import request from '@/config/axios' + +export interface WarehouseAreaVO { + id: number + warehouseId: number + areaCode: string + areaName: string + areaSize: number + description: string + status: number + createTime: string +} + +export const WarehouseAreaApi = { + getWarehouseAreaPage: async (params: any) => { + return await request.get({ url: `/erp/warehouse-area/page`, params }) + }, + + getWarehouseArea: async (id: number) => { + return await request.get({ url: `/erp/warehouse-area/get?id=` + id }) + }, + + createWarehouseArea: async (data: WarehouseAreaVO) => { + return await request.post({ url: `/erp/warehouse-area/create`, data }) + }, + + updateWarehouseArea: async (data: WarehouseAreaVO) => { + return await request.put({ url: `/erp/warehouse-area/update`, data }) + }, + + deleteWarehouseArea: async (id: number) => { + return await request.delete({ url: `/erp/warehouse-area/delete?id=` + id }) + } +} diff --git a/src/api/erp/stock/warehouselocation/index.ts b/src/api/erp/stock/warehouselocation/index.ts new file mode 100644 index 00000000..5bb7a0a1 --- /dev/null +++ b/src/api/erp/stock/warehouselocation/index.ts @@ -0,0 +1,40 @@ +import request from '@/config/axios' + +export interface WarehouseLocationVO { + id: number + warehouseId: number + areaId: number + code: string + name: string + areaSize: number + maxLoadWeight: number + positionX: number + positionY: number + positionZ: number + allowProductMix: boolean + allowBatchMix: boolean + status: number + createTime: string +} + +export const WarehouseLocationApi = { + getWarehouseLocationPage: async (params: any) => { + return await request.get({ url: `/erp/warehouse-location/page`, params }) + }, + + getWarehouseLocation: async (id: number) => { + return await request.get({ url: `/erp/warehouse-location/get?id=` + id }) + }, + + createWarehouseLocation: async (data: WarehouseLocationVO) => { + return await request.post({ url: `/erp/warehouse-location/create`, data }) + }, + + updateWarehouseLocation: async (data: WarehouseLocationVO) => { + return await request.put({ url: `/erp/warehouse-location/update`, data }) + }, + + deleteWarehouseLocation: async (id: number) => { + return await request.delete({ url: `/erp/warehouse-location/delete?id=` + id }) + } +} diff --git a/src/locales/en.ts b/src/locales/en.ts index bd588c96..0b884c8b 100644 --- a/src/locales/en.ts +++ b/src/locales/en.ts @@ -59,6 +59,9 @@ export default { copy: 'Copy', copySuccess: 'Copy Success', copyError: 'Copy Error', + yes: 'Yes', + no: 'No', + code:'Auto-generate on Save' code: 'Auto-generate on Save' }, ReportDashboard: { @@ -287,6 +290,58 @@ export default { cancel: 'cancel', exportName: 'Warehouse.xls' }, + WarehouseArea: { + warehouseId: 'Warehouse', + areaCode: 'Area Code', + areaName: 'Area Name', + areaSize: 'Area Size (㎡)', + description: 'Description', + status: 'Status', + createTime: 'Create Time', + placeholderWarehouseId: 'Please select warehouse', + placeholderAreaCode: 'Please enter area code', + placeholderAreaName: 'Please enter area name', + placeholderAreaSize: 'Please enter area size', + placeholderDescription: 'Please enter description', + placeholderStatus: 'Please select status', + validatorWarehouseIdRequired: 'Warehouse is required', + validatorAreaCodeRequired: 'Area code is required', + validatorAreaNameRequired: 'Area name is required', + validatorStatusRequired: 'Status is required' + }, + WarehouseLocation: { + warehouseId: 'Warehouse', + areaId: 'Area', + code: 'Location Code', + name: 'Location Name', + areaSize: 'Area Size (㎡)', + maxLoadWeight: 'Max Load Weight', + position: 'Position (X,Y,Z)', + positionX: 'Position X', + positionY: 'Position Y', + positionZ: 'Position Z', + allowProductMix: 'Allow Product Mix', + allowBatchMix: 'Allow Batch Mix', + status: 'Status', + createTime: 'Create Time', + placeholderWarehouseId: 'Please select warehouse', + placeholderAreaId: 'Please select area', + placeholderCode: 'Please enter location code', + placeholderName: 'Please enter location name', + placeholderAreaSize: 'Please enter area size', + placeholderMaxLoadWeight: 'Please enter max load weight', + placeholderPositionX: 'Please enter position X', + placeholderPositionY: 'Please enter position Y', + placeholderPositionZ: 'Please enter position Z', + placeholderStatus: 'Please select status', + validatorWarehouseIdRequired: 'Warehouse is required', + validatorAreaIdRequired: 'Area is required', + validatorCodeRequired: 'Location code is required', + validatorNameRequired: 'Location name is required', + validatorAllowProductMixRequired: 'Allow product mix is required', + validatorAllowBatchMixRequired: 'Allow batch mix is required', + validatorStatusRequired: 'Status is required' + }, Stock: { product: 'Product', warehouse: 'Warehouse', @@ -1280,7 +1335,10 @@ export default { qrcodeEmpty: 'No QR code', validatorDeviceCodeRequired: 'Code can not be empty', gjTitle: 'Select key components', - bjTitle: 'Select spare parts' + bjTitle: 'Select spare parts', + Detail: { + invalidId: 'Invalid device ID' + } }, // Critical Component EquipmentKeyItems: { @@ -4367,7 +4425,12 @@ export default { detailTabRelatedPlan: 'Related Plans', detailTabQualityInfo: 'Quality Info', detailTabBaogongInfo: 'Work Report', - exportFilename: 'ProductionReport' + exportFilename: 'ProductionReport', + tableOperate: 'Operate', + detail: 'Detail' + }, + Detail: { + invalidId: 'Invalid parameter, task ID cannot be empty' }, BasicInfo: { buttonRefresh: 'Refresh', diff --git a/src/locales/zh-CN.ts b/src/locales/zh-CN.ts index 16e4c65b..bcbdaec4 100644 --- a/src/locales/zh-CN.ts +++ b/src/locales/zh-CN.ts @@ -59,6 +59,8 @@ export default { copy: '复制', copySuccess: '复制成功', copyError: '复制失败', + yes: '是', + no: '否', code: '编码保存后自动生成' }, ReportDashboard: { @@ -287,6 +289,58 @@ export default { cancel: '取消', exportName: '仓库.xls' }, + WarehouseArea: { + warehouseId: '所属仓库', + areaCode: '库区编码', + areaName: '库区名称', + areaSize: '面积(㎡)', + description: '库区描述', + status: '开启状态', + createTime: '创建时间', + placeholderWarehouseId: '请选择所属仓库', + placeholderAreaCode: '请输入库区编码', + placeholderAreaName: '请输入库区名称', + placeholderAreaSize: '请输入面积', + placeholderDescription: '请输入库区描述', + placeholderStatus: '请选择开启状态', + validatorWarehouseIdRequired: '所属仓库不能为空', + validatorAreaCodeRequired: '库区编码不能为空', + validatorAreaNameRequired: '库区名称不能为空', + validatorStatusRequired: '开启状态不能为空' + }, + WarehouseLocation: { + warehouseId: '所属仓库', + areaId: '所属库区', + code: '库位编码', + name: '库位名称', + areaSize: '面积(㎡)', + maxLoadWeight: '最大载重量', + position: '库位位置(X,Y,Z)', + positionX: '位置X', + positionY: '位置Y', + positionZ: '位置Z', + allowProductMix: '允许产品混放', + allowBatchMix: '允许批次混放', + status: '开启状态', + createTime: '创建时间', + placeholderWarehouseId: '请选择所属仓库', + placeholderAreaId: '请选择所属库区', + placeholderCode: '请输入库位编码', + placeholderName: '请输入库位名称', + placeholderAreaSize: '请输入面积', + placeholderMaxLoadWeight: '请输入最大载重量', + placeholderPositionX: '请输入位置X', + placeholderPositionY: '请输入位置Y', + placeholderPositionZ: '请输入位置Z', + placeholderStatus: '请选择开启状态', + validatorWarehouseIdRequired: '所属仓库不能为空', + validatorAreaIdRequired: '所属库区不能为空', + validatorCodeRequired: '库位编码不能为空', + validatorNameRequired: '库位名称不能为空', + validatorAllowProductMixRequired: '是否允许产品混放不能为空', + validatorAllowBatchMixRequired: '是否允许批次混放不能为空', + validatorStatusRequired: '开启状态不能为空' + }, Stock: { product: '产品', warehouse: '仓库', @@ -1195,7 +1249,7 @@ export default { statusDisabled: '不启用', deviceType: '类型', deviceSpec: '规格型号', - /* deviceModel: '型号',*/ + deviceModel: '型号', isSchedueld: '是否排产', ratedCapacity: '额定产能', yes: '是', @@ -1270,7 +1324,10 @@ export default { qrcodeEmpty: '暂无二维码', validatorDeviceCodeRequired: '编码不能为空', gjTitle: '选择关键件', - bjTitle: '选择备件' + bjTitle: '选择备件', + Detail: { + invalidId: '无效的设备ID' + } }, // 设备关键件 EquipmentKeyItems: { @@ -4578,7 +4635,12 @@ export default { detailTabRelatedPlan: '关联计划', detailTabQualityInfo: '质检信息', detailTabBaogongInfo: '报工信息', - exportFilename: '生产报表' + exportFilename: '生产报表', + tableOperate: '操作', + detail: '详情' + }, + Detail: { + invalidId: '参数错误,任务单ID不能为空' }, BasicInfo: { buttonRefresh: '刷新', diff --git a/src/router/modules/remaining.ts b/src/router/modules/remaining.ts index 2a28f0b1..d1e56667 100644 --- a/src/router/modules/remaining.ts +++ b/src/router/modules/remaining.ts @@ -694,6 +694,28 @@ const remainingRouter: AppRouteRecordRaw[] = [ activeMenu: '/mes/plan' }, component: () => import('@/views/mes/plan/index.vue') + }, + { + path: 'production-report/detail/:id', + name: 'MesProductionReportDetail', + meta: { + title: '生产报工详情', + noCache: true, + hidden: true, + activeMenu: '/mes/productionReport' + }, + component: () => import('@/views/mes/productionReport/detail/index.vue') + }, + { + path: 'device-ledger/detail/:id', + name: 'MesDeviceLedgerDetail', + meta: { + title: '设备台账详情', + noCache: true, + hidden: true, + activeMenu: '/mes/deviceledger' + }, + component: () => import('@/views/mes/deviceledger/detail/index.vue') } ] } diff --git a/src/views/erp/product/product/ProductForm.vue b/src/views/erp/product/product/ProductForm.vue index e5e1f420..784f2609 100644 --- a/src/views/erp/product/product/ProductForm.vue +++ b/src/views/erp/product/product/ProductForm.vue @@ -12,7 +12,7 @@ - + {{ t('action.edit') }} + + {{ t('action.detail') }} + + + + +
+ + {{ detailData.name }} + {{ detailData.address }} + {{ detailData.principal }} + {{ detailData.remark || '-' }} + {{ detailData.sort }} + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+
diff --git a/src/views/erp/warehousearea/index.vue b/src/views/erp/warehousearea/index.vue new file mode 100644 index 00000000..1feed687 --- /dev/null +++ b/src/views/erp/warehousearea/index.vue @@ -0,0 +1,201 @@ + + + diff --git a/src/views/erp/warehouselocation/WarehouseLocationForm.vue b/src/views/erp/warehouselocation/WarehouseLocationForm.vue new file mode 100644 index 00000000..f2fe9a1d --- /dev/null +++ b/src/views/erp/warehouselocation/WarehouseLocationForm.vue @@ -0,0 +1,227 @@ + + + diff --git a/src/views/erp/warehouselocation/index.vue b/src/views/erp/warehouselocation/index.vue new file mode 100644 index 00000000..9d92f67c --- /dev/null +++ b/src/views/erp/warehouselocation/index.vue @@ -0,0 +1,263 @@ + + + diff --git a/src/views/mes/deviceledger/detail/index.vue b/src/views/mes/deviceledger/detail/index.vue new file mode 100644 index 00000000..360de443 --- /dev/null +++ b/src/views/mes/deviceledger/detail/index.vue @@ -0,0 +1,938 @@ + + + + + diff --git a/src/views/mes/deviceledger/index.vue b/src/views/mes/deviceledger/index.vue index a49541c8..76c94b6c 100644 --- a/src/views/mes/deviceledger/index.vue +++ b/src/views/mes/deviceledger/index.vue @@ -245,459 +245,6 @@ - - -
-
{{ - t('EquipmentManagement.EquipmentLedger.detail') - }} -
- - - -
- - - {{ detailData?.deviceCode ?? '' }} - - - {{ detailData?.deviceName ?? '' }} - - - - - - - {{ detailData?.deviceModel ?? '' }} - - - {{ detailData?.deviceSpec ?? '' }} - - - {{ - getDeviceTypeName(detailData?.deviceTypeName ?? detailData?.deviceType) - }} - - - - - - - {{ detailData?.deviceLocation ?? '' }} - - - {{ detailData?.deviceManagerName ?? '' }} - - - {{ formatDetailDate(detailData?.productionDate) }} - - - {{ - formatDetailDate(detailData?.factoryEntryDate) - }} - - {{ - detailData?.remark ?? detailData?.deviceRemark ?? '' - }} - - - {{ detailData?.creatorName ?? '' }} - - - {{ formatDetailDate(detailData?.createTime) }} - - - {{ formatDetailDate(detailData?.updateTime) }} - - - - - - - - -
- -
- - -
- - {{ - t('common.query') - }} - - {{ t('common.reset') }} - - - {{ t('action.export') }} - -
- - - - - - - -
- -
- - {{ - t('common.query') - }} - - {{ t('common.reset') }} - - - {{ t('action.export') }} - -
- - - - - - - -
- -
- - {{ - t('common.query') - }} - - {{ t('common.reset') }} - - - {{ t('action.export') }} - -
- - - - -
-
-
- {{ row.subjectCode ?? '-' }} - {{ - row.subjectName ?? '-' - }} -
-
-
- {{ - t('EquipmentManagement.EquipmentLedger.projectName') - }} - {{ - row.subjectContent ?? '-' - }} -
-
- {{ - t('EquipmentManagement.EquipmentLedger.repairResult') - }} - - - {{ getResultLabel(row.repairResult ?? row.result) }} - - -
-
- {{ - t('EquipmentManagement.EquipmentLedger.remark') - }} - {{ - row.remark ?? '-' - }} -
-
- {{ - t('EquipmentManagement.EquipmentLedger.finishDate') - }} - {{ - String(formatHistoryTime(row.finishDate)).split(' ')[0] - }} -
-
- - - -
-
-
-
-
-
-
- -
- - - {{ t('action.export') }} - -
- - - - - - - -
- -
- - - {{ t('action.export') }} - -
- - - - - - - -
- - - - - - - - - -
-
@@ -706,18 +253,13 @@ + + diff --git a/src/views/mes/productionReport/detail/index.vue b/src/views/mes/productionReport/detail/index.vue new file mode 100644 index 00000000..d3fe5bbc --- /dev/null +++ b/src/views/mes/productionReport/detail/index.vue @@ -0,0 +1,152 @@ + + + + + diff --git a/src/views/mes/productionReport/index.vue b/src/views/mes/productionReport/index.vue index ed786dd7..04815c51 100644 --- a/src/views/mes/productionReport/index.vue +++ b/src/views/mes/productionReport/index.vue @@ -90,8 +90,6 @@ :data="list" :stripe="true" :show-overflow-tooltip="true" - highlight-current-row - @current-change="handleCurrentChange" > @@ -128,6 +126,13 @@ + + + - - - - - - - - - - - - - - - - -