From 95a2d2d783267e1bec27cc4116af98747324da7b Mon Sep 17 00:00:00 2001 From: Ledo Date: Tue, 6 May 2025 22:48:05 +0800 Subject: [PATCH] =?UTF-8?q?1.=E8=BF=87=E7=A8=8B=E6=A3=80=E3=80=81=E7=BB=88?= =?UTF-8?q?=E6=A3=80=20=E9=83=BD=E7=94=9F=E6=88=90=E4=B8=A4=E6=9D=A1?= =?UTF-8?q?=E6=95=B0=E6=8D=AE=E4=BF=AE=E6=AD=A3=EF=BC=88=E6=B7=BB=E5=8A=A0?= =?UTF-8?q?=E8=BD=AC=E5=9C=88=EF=BC=89=206=E3=80=81=E4=B8=8B=E4=B8=80?= =?UTF-8?q?=E9=A1=B5=20=E6=8F=90=E7=A4=BA=20=20=E6=98=AF=E5=90=A6=E4=BF=9D?= =?UTF-8?q?=E5=AD=98=206=E3=80=81=E6=B4=BE=E5=B7=A5=E5=8D=95=E8=AF=A6?= =?UTF-8?q?=E6=83=85=20=E6=98=BE=E7=A4=BA=E4=BF=A1=E6=81=AF=E9=94=99?= =?UTF-8?q?=E8=AF=AF=E6=B2=A1=E6=9C=89=E8=BD=AC=E6=8D=A2=207=E3=80=81=20?= =?UTF-8?q?=E7=A7=BB=E5=8A=A8=E7=AB=AF=20=E6=8A=A5=E5=B7=A5=20=E5=A2=9E?= =?UTF-8?q?=E5=8A=A0=E4=B8=8B=E4=B8=80=E4=B8=AA=E5=B7=A5=E5=BA=8F?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../taskdispatch/TaskDispatchDetailDO.java | 2 + .../service/pgmaster/PgMasterServiceImpl.java | 1 + .../taskdispatch/TaskDispatchServiceImpl.java | 28 ++++++ .../views/heli/taskdispatch/detailDialog.vue | 93 ++++++++++++++----- .../src/views/heli/taskdispatch/index.vue | 2 +- .../assembleReport/assembleReport-detail.vue | 4 +- .../productionReport/components/dataItem.vue | 4 +- .../productionReport-detail.vue | 4 +- 8 files changed, 110 insertions(+), 28 deletions(-) diff --git a/mes-module-heli/mes-module-heli-biz/src/main/java/com/chanko/yunxi/mes/module/heli/dal/dataobject/taskdispatch/TaskDispatchDetailDO.java b/mes-module-heli/mes-module-heli-biz/src/main/java/com/chanko/yunxi/mes/module/heli/dal/dataobject/taskdispatch/TaskDispatchDetailDO.java index 9a32d3f..75e1f4c 100644 --- a/mes-module-heli/mes-module-heli-biz/src/main/java/com/chanko/yunxi/mes/module/heli/dal/dataobject/taskdispatch/TaskDispatchDetailDO.java +++ b/mes-module-heli/mes-module-heli-biz/src/main/java/com/chanko/yunxi/mes/module/heli/dal/dataobject/taskdispatch/TaskDispatchDetailDO.java @@ -174,5 +174,7 @@ public class TaskDispatchDetailDO extends BaseDO { private String workerId; @TableField(exist = false) private String workerName; + @TableField(exist = false) + private String nextProcedureName; } diff --git a/mes-module-heli/mes-module-heli-biz/src/main/java/com/chanko/yunxi/mes/module/heli/service/pgmaster/PgMasterServiceImpl.java b/mes-module-heli/mes-module-heli-biz/src/main/java/com/chanko/yunxi/mes/module/heli/service/pgmaster/PgMasterServiceImpl.java index 1c54cff..a181551 100644 --- a/mes-module-heli/mes-module-heli-biz/src/main/java/com/chanko/yunxi/mes/module/heli/service/pgmaster/PgMasterServiceImpl.java +++ b/mes-module-heli/mes-module-heli-biz/src/main/java/com/chanko/yunxi/mes/module/heli/service/pgmaster/PgMasterServiceImpl.java @@ -60,6 +60,7 @@ public class PgMasterServiceImpl implements PgMasterService { @Override public Boolean insertPgList(Long task_id,Long project_id,Long bomMxId){ + //213 605 //查询BOM明细 List processBomDOList = processBomMapper.selectBomMx(task_id,project_id,bomMxId); List pgMasterLineDOList = new ArrayList<>(); diff --git a/mes-module-heli/mes-module-heli-biz/src/main/java/com/chanko/yunxi/mes/module/heli/service/taskdispatch/TaskDispatchServiceImpl.java b/mes-module-heli/mes-module-heli-biz/src/main/java/com/chanko/yunxi/mes/module/heli/service/taskdispatch/TaskDispatchServiceImpl.java index 7e6d7b3..0fb7d9c 100644 --- a/mes-module-heli/mes-module-heli-biz/src/main/java/com/chanko/yunxi/mes/module/heli/service/taskdispatch/TaskDispatchServiceImpl.java +++ b/mes-module-heli/mes-module-heli-biz/src/main/java/com/chanko/yunxi/mes/module/heli/service/taskdispatch/TaskDispatchServiceImpl.java @@ -15,6 +15,7 @@ import com.chanko.yunxi.mes.module.heli.dal.dataobject.bdgzsomthing.bdgzsomthing import com.chanko.yunxi.mes.module.heli.dal.dataobject.equipmanufacture.EquipManufactureDO; import com.chanko.yunxi.mes.module.heli.dal.dataobject.fpuserdetail.FpUserDetailDO; import com.chanko.yunxi.mes.module.heli.dal.dataobject.plan.PlanDO; +import com.chanko.yunxi.mes.module.heli.dal.dataobject.procedure.ProcedureDO; import com.chanko.yunxi.mes.module.heli.dal.dataobject.projectorder.ProjectOrderSubDO; import com.chanko.yunxi.mes.module.heli.dal.dataobject.serialnumber.SerialNumberDO; import com.chanko.yunxi.mes.module.heli.dal.dataobject.taskdispatch.TaskDispatchDO; @@ -24,6 +25,7 @@ import com.chanko.yunxi.mes.module.heli.dal.mysql.bdgzsomthing.bdgzsomthingMappe import com.chanko.yunxi.mes.module.heli.dal.mysql.equipmanufacture.EquipManufactureMapper; import com.chanko.yunxi.mes.module.heli.dal.mysql.fpuserdetail.FpUserDetailMapper; import com.chanko.yunxi.mes.module.heli.dal.mysql.plan.PlanMapper; +import com.chanko.yunxi.mes.module.heli.dal.mysql.procedure.ProcedureMapper; import com.chanko.yunxi.mes.module.heli.dal.mysql.projectorder.ProjectOrderSubMapper; import com.chanko.yunxi.mes.module.heli.dal.mysql.taskdispatch.TaskDispatchDetailMapper; import com.chanko.yunxi.mes.module.heli.dal.mysql.taskdispatch.TaskDispatchMapper; @@ -86,6 +88,8 @@ public class TaskDispatchServiceImpl implements TaskDispatchService { private PgMasterService pgMasterService; @Resource private bdgzsomthingMapper bdgzsomthingMapper; + @Resource + private ProcedureMapper procedureMapper; @Override @Transactional(rollbackFor = Exception.class) public Long createTaskDispatch(TaskDispatchSaveReqVO createReqVO) { @@ -358,6 +362,30 @@ public class TaskDispatchServiceImpl implements TaskDispatchService { postIds.add(fpUserDetailDO.getPostId()); } PageResult taskDispatchDetailDOPageResult = taskDispatchDetailMapper.selectPageWx(pageReqVO, postIds); + List list = taskDispatchDetailDOPageResult.getList(); + HashMap hashMap = new HashMap<>(); + if (CollUtil.isNotEmpty(list)){ + for (TaskDispatchDetailDO taskDispatchDetailDO : list) { + List taskDispatchDetailDOS = taskDispatchDetailMapper.selectList(new LambdaQueryWrapperX() + .eq(TaskDispatchDetailDO::getDispatchId, taskDispatchDetailDO.getDispatchId()) + .eq(TaskDispatchDetailDO::getSort, taskDispatchDetailDO.getSort() + 1)); + if (CollUtil.isNotEmpty(taskDispatchDetailDOS)){ + TaskDispatchDetailDO taskDispatchDetailDO1 = taskDispatchDetailDOS.get(0); + Long procedureId = taskDispatchDetailDO1.getProcedureId(); + if (hashMap.get(procedureId)==null){ + ProcedureDO procedureDO = procedureMapper.selectById(procedureId); + if (procedureDO != null){ + hashMap.put(procedureId, procedureDO.getName()); + taskDispatchDetailDO.setNextProcedureName(procedureDO.getName()); + } + }else{ + taskDispatchDetailDO.setNextProcedureName(hashMap.get(procedureId)); + } + + } + } + //非空遍历找下一道工序Id + } return taskDispatchDetailDOPageResult; } @Override diff --git a/mes-ui/mes-ui-admin-vue3/src/views/heli/taskdispatch/detailDialog.vue b/mes-ui/mes-ui-admin-vue3/src/views/heli/taskdispatch/detailDialog.vue index 6fe6974..ef58614 100644 --- a/mes-ui/mes-ui-admin-vue3/src/views/heli/taskdispatch/detailDialog.vue +++ b/mes-ui/mes-ui-admin-vue3/src/views/heli/taskdispatch/detailDialog.vue @@ -1,5 +1,5 @@ diff --git a/mes-ui/mini-app/src/pages/assembleReport/assembleReport-detail.vue b/mes-ui/mini-app/src/pages/assembleReport/assembleReport-detail.vue index 9036873..8d39a2d 100644 --- a/mes-ui/mini-app/src/pages/assembleReport/assembleReport-detail.vue +++ b/mes-ui/mini-app/src/pages/assembleReport/assembleReport-detail.vue @@ -133,11 +133,13 @@ onLoad(async (options: any) => { // 生产完成 const handleComplate = async () => { + isLoading.value = true const params = { id: detailInfo.value?.id, active: 'FINISH', } const data = await postOperateAPI(params) + isLoading.value = false const url = `/pages/productionReport/productionReport-detail?id=${detailInfo.value.id}` uni.redirectTo({ url, @@ -325,7 +327,7 @@ const handleStop = async () => { .product-status { width: 140rpx; - border-raduis: 10rpx; + border-radius: 10rpx; text-align: center; padding: 8rpx 12rpx; diff --git a/mes-ui/mini-app/src/pages/productionReport/components/dataItem.vue b/mes-ui/mini-app/src/pages/productionReport/components/dataItem.vue index 709da50..782112c 100644 --- a/mes-ui/mini-app/src/pages/productionReport/components/dataItem.vue +++ b/mes-ui/mini-app/src/pages/productionReport/components/dataItem.vue @@ -136,7 +136,9 @@ const onRefresherrefresh = async () => { 派工单: - ( 单号:{{ item.dispatchCode }} ) + {{ '(单号:'+ item.dispatchCode+') '}} + 下一道工序: + {{ item.nextProcedureName == null ? '无':item.nextProcedureName}} 项目名称:{{ item.projectCode + ' ' + item.projectName }} diff --git a/mes-ui/mini-app/src/pages/productionReport/productionReport-detail.vue b/mes-ui/mini-app/src/pages/productionReport/productionReport-detail.vue index 7a915f5..13989dc 100644 --- a/mes-ui/mini-app/src/pages/productionReport/productionReport-detail.vue +++ b/mes-ui/mini-app/src/pages/productionReport/productionReport-detail.vue @@ -126,11 +126,13 @@ onLoad(async (options: any) => { // 生产完成 const handleComplate = async () => { + isLoading.value = true; const params = { id: detailInfo.value?.id, active: 'FINISH', } const data = await postOperateAPI(params) + isLoading.value = false const url = `/pages/productionReport/productionReport-detail?id=${detailInfo.value.id}` uni.redirectTo({ url, @@ -221,7 +223,7 @@ const handleStop = async () => { 预计生产日期:{{ detailInfo.startTime }} ~ {{ detailInfo.endTime }} + @click="handleComplate" > 生产完成