diff --git a/mes-module-heli/mes-module-heli-api/src/main/java/com/chanko/yunxi/mes/module/heli/enums/ErrorCodeConstants.java b/mes-module-heli/mes-module-heli-api/src/main/java/com/chanko/yunxi/mes/module/heli/enums/ErrorCodeConstants.java index 9658ac59..36e7c972 100644 --- a/mes-module-heli/mes-module-heli-api/src/main/java/com/chanko/yunxi/mes/module/heli/enums/ErrorCodeConstants.java +++ b/mes-module-heli/mes-module-heli-api/src/main/java/com/chanko/yunxi/mes/module/heli/enums/ErrorCodeConstants.java @@ -129,6 +129,7 @@ public interface ErrorCodeConstants { ErrorCode TASK_DISPATCH_TASK_REPORT_AMOUNT_EXCESS = new ErrorCode(1_009_006, "无法超额报工"); ErrorCode TASK_REPORT_OTHER_PERSON_NO_SUBMIT = new ErrorCode(1_009_020, "其他人员尚未报工,无法结束生产"); ErrorCode THE_REPORT_APPLICATION_NOT_ENDED = new ErrorCode(1_009_021, "该报工没有结束,请刷新界面"); + ErrorCode THE_DATA_DOES_NOT_EXIST = new ErrorCode(1_009_022, "该数据不存在,请刷新界面"); //1_009_021已被使用 /*************质量管理***********/ ErrorCode UNQUALIFIED_NOTIFICATION_NOT_EXISTS = new ErrorCode(1_010_001, "品质异常通知单审核不存在"); diff --git a/mes-module-heli/mes-module-heli-biz/src/main/java/com/chanko/yunxi/mes/module/heli/service/taskreport/TaskReportServiceImpl.java b/mes-module-heli/mes-module-heli-biz/src/main/java/com/chanko/yunxi/mes/module/heli/service/taskreport/TaskReportServiceImpl.java index 15797a25..567a1275 100644 --- a/mes-module-heli/mes-module-heli-biz/src/main/java/com/chanko/yunxi/mes/module/heli/service/taskreport/TaskReportServiceImpl.java +++ b/mes-module-heli/mes-module-heli-biz/src/main/java/com/chanko/yunxi/mes/module/heli/service/taskreport/TaskReportServiceImpl.java @@ -92,14 +92,14 @@ public class TaskReportServiceImpl implements TaskReportService { public void rework(Long id, String remark) { TaskReportDO taskReportDO = taskReportMapper.selectById(id); if (taskReportDO == null) { - throw exception(TASK_REPORT_NOT_EXISTS); + throw exception(THE_DATA_DOES_NOT_EXIST); } TaskDispatchDetailDO taskDispatchDetailDO = taskDispatchDetailMapper.selectById(taskReportDO.getDispatchDetailId()); if (taskDispatchDetailDO != null) { - if (taskDispatchDetailDO.getReportProcess() != 2) { - throw exception(THE_REPORT_APPLICATION_NOT_ENDED); + if (taskDispatchDetailDO.getProcedureStatus() != 2) { + throw exception(TASK_IN_REPORT_NOT_REWORK); } else { - taskDispatchDetailDO.setReportProcess(1); + taskDispatchDetailDO.setProcedureStatus(1); taskDispatchDetailDO.setReturnRemark(remark); taskDispatchDetailMapper.updateById(taskDispatchDetailDO); } diff --git a/mes-ui/mes-ui-admin-vue3/src/views/heli/taskreport/index.vue b/mes-ui/mes-ui-admin-vue3/src/views/heli/taskreport/index.vue index 05d1c318..6e195f67 100644 --- a/mes-ui/mes-ui-admin-vue3/src/views/heli/taskreport/index.vue +++ b/mes-ui/mes-ui-admin-vue3/src/views/heli/taskreport/index.vue @@ -169,6 +169,7 @@ 返工