From 950301315da985e3204fc00f0ef407f56489eb8f Mon Sep 17 00:00:00 2001 From: anthonywj Date: Mon, 19 Jun 2023 15:07:21 +0800 Subject: [PATCH] =?UTF-8?q?=E6=9B=B4=E6=96=B0=E5=AE=A1=E6=A0=B8=E4=BA=BA?= =?UTF-8?q?=EF=BC=8C=E6=A0=B8=E5=AF=B9=E4=BA=BA=EF=BC=8C=E4=BE=9B=E5=BA=94?= =?UTF-8?q?=E5=95=86=E7=BC=96=E8=BE=91=E4=BF=A1=E6=81=AFbug?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../inout/IoCodeTempController.java | 2 +- .../controller/inout/IoOrderController.java | 14 +++++----- .../api/entity/basic/UdiProductEntity.java | 26 ------------------- .../service/inout/IoCheckInoutService.java | 8 ++++-- 4 files changed, 14 insertions(+), 36 deletions(-) diff --git a/src/main/java/com/glxp/api/controller/inout/IoCodeTempController.java b/src/main/java/com/glxp/api/controller/inout/IoCodeTempController.java index ece1b278a..7abcef388 100644 --- a/src/main/java/com/glxp/api/controller/inout/IoCodeTempController.java +++ b/src/main/java/com/glxp/api/controller/inout/IoCodeTempController.java @@ -375,7 +375,7 @@ public class IoCodeTempController extends BaseController { if (udiInfoEntity == null) { return ResultVOUtils.error(500, "耗材字典不存在此产品!"); } - if (!udiInfoEntity.getAllowNoBatch()) { + if (!IntUtil.value(udiInfoEntity.getAllowNoBatch())) { if (StrUtil.isEmpty(udiEntity.getSerialNo()) && StrUtil.isEmpty(udiEntity.getBatchNo())) { return ResultVOUtils.error(500, "序列号与批次号不能同时为空!"); } diff --git a/src/main/java/com/glxp/api/controller/inout/IoOrderController.java b/src/main/java/com/glxp/api/controller/inout/IoOrderController.java index 6c8132534..41aaa7365 100644 --- a/src/main/java/com/glxp/api/controller/inout/IoOrderController.java +++ b/src/main/java/com/glxp/api/controller/inout/IoOrderController.java @@ -247,7 +247,7 @@ public class IoOrderController extends BaseController { return tempResponse; //todo 目前先去掉因为不能改变状态 有问题可以看一下这个方法 // if (orderEntity.getStatus() != ConstantStatus.ORDER_STATUS_TEMP_SAVE){ - ioAddInoutService.dealProcess(orderEntity); + ioAddInoutService.dealProcess(orderEntity); // } @@ -359,7 +359,7 @@ public class IoOrderController extends BaseController { public BaseResponse checkSubmitEnable(IoOrderEntity orderEntity) { - if(orderEntity==null){ + if (orderEntity == null) { return ResultVOUtils.error(500, "提交失败,请先添加物资!"); } @@ -735,7 +735,7 @@ public class IoOrderController extends BaseController { @PostMapping("/udiwms/stock/order/change") public BaseResponse stockOrderChange(@RequestBody AddOrderChangeRequest addOrderChangeRequest) { - + AuthAdmin authAdmin = getUser(); IoOrderEntity originOrder = orderService.findByBillNo(addOrderChangeRequest.getOrderId()); IoOrderEntity newOrder = new IoOrderEntity(); List originCodes = codeService.findByOrderId(originOrder.getBillNo()); @@ -748,7 +748,8 @@ public class IoOrderController extends BaseController { newOrder.setFromDeptCode(fromInv.getParentId()); } - + newOrder.setCreateUser(authAdmin.getId() + ""); + newOrder.setUpdateUser(authAdmin.getId() + ""); InvWarehouseEntity invWarehouseEntity = invWarehouseService.findByInvSubByCode(addOrderChangeRequest.getInvCode()); newOrder.setInvCode(addOrderChangeRequest.getInvCode()); newOrder.setDeptCode(invWarehouseEntity.getParentId()); @@ -829,8 +830,8 @@ public class IoOrderController extends BaseController { return ResultVOUtils.success(); } - @GetMapping ("/udiwms/inout/order/getUserBean") - public BaseResponse getUserBean(){ + @GetMapping("/udiwms/inout/order/getUserBean") + public BaseResponse getUserBean() { AuthAdmin userBean = customerService.getUserBean(); @@ -838,5 +839,4 @@ public class IoOrderController extends BaseController { } - } diff --git a/src/main/java/com/glxp/api/entity/basic/UdiProductEntity.java b/src/main/java/com/glxp/api/entity/basic/UdiProductEntity.java index 11e5a3176..c1893bd26 100644 --- a/src/main/java/com/glxp/api/entity/basic/UdiProductEntity.java +++ b/src/main/java/com/glxp/api/entity/basic/UdiProductEntity.java @@ -96,30 +96,4 @@ public class UdiProductEntity { private String categoryName; private Date updateTime; - - public Boolean getAllowNoBatch() { - if (allowNoBatch == null) - return false; - return allowNoBatch; - } - - public Boolean getAllowNoExpire() { - if (allowNoExpire == null) - return false; - return allowNoExpire; - } - - public Boolean getAllowNoProduct() { - if (allowNoProduct == null) - return false; - return allowNoProduct; - } - - public Boolean getAllowNoSerial() { - if (allowNoSerial == null) - return false; - return allowNoSerial; - } - - } diff --git a/src/main/java/com/glxp/api/service/inout/IoCheckInoutService.java b/src/main/java/com/glxp/api/service/inout/IoCheckInoutService.java index 7b97a2176..69bb21bc2 100644 --- a/src/main/java/com/glxp/api/service/inout/IoCheckInoutService.java +++ b/src/main/java/com/glxp/api/service/inout/IoCheckInoutService.java @@ -329,7 +329,6 @@ public class IoCheckInoutService { codeService.insert(codeEnttity); } codeTempService.deleteByBillNo(orderEntity.getBillNo()); - orderEntity.setStatus(ConstantStatus.ORDER_STATUS_CHECK_SUCCESS); orderEntity.setDealStatus(ConstantStatus.ORDER_DEAL_POST); orderEntity.setUpdateTime(new Date()); @@ -748,7 +747,9 @@ public class IoCheckInoutService { orderEntity.setStatus(ConstantStatus.ORDER_STATUS_CHECK_REW); } } - + if (StrUtil.isEmpty(orderEntity.getCheckUser())) { + orderEntity.setCheckUser(orderEntity.getCreateUser()); + } if (orderEntity.getStatus() == ConstantStatus.ORDER_STATUS_CHECK_REW) { orderEntity.setDealStatus(ConstantStatus.ORDER_DEAL_REW); orderEntity.setUpdateTime(new Date()); @@ -810,6 +811,9 @@ public class IoCheckInoutService { orderEntity.setDealStatus(ConstantStatus.ORDER_DEAL_CHECK); orderEntity.setUpdateTime(new Date()); orderEntity.setAuditTime(new Date()); + if (StrUtil.isEmpty(orderEntity.getReviewUser())) { + orderEntity.setReviewUser(orderEntity.getReviewUser()); + } orderService.update(orderEntity); genInv(orderEntity, bussinessTypeEntity); }