diff --git a/mhd_wms/src/main/java/com/mhd/wms/domain/stockShelfOrder/service/StockShelfOrderDomainService.java b/mhd_wms/src/main/java/com/mhd/wms/domain/stockShelfOrder/service/StockShelfOrderDomainService.java index c516f3613..8579c78e2 100644 --- a/mhd_wms/src/main/java/com/mhd/wms/domain/stockShelfOrder/service/StockShelfOrderDomainService.java +++ b/mhd_wms/src/main/java/com/mhd/wms/domain/stockShelfOrder/service/StockShelfOrderDomainService.java @@ -539,8 +539,21 @@ public class StockShelfOrderDomainService { BigDecimal oldInventoryQuantity = materialInventoryPO.getInventoryQuantity(); BigDecimal newAllocationQuantity = materialInventoryPO.getAllocationQuantity().add(shelfMaterialDetail.getShelvesQuantity()); BigDecimal oldAllocationQuantity = materialInventoryPO.getAllocationQuantity(); + BigDecimal oldArea = materialInventoryPO.getArea(); + BigDecimal newArea = oldArea.add(shelfMaterialDetail.getTotalArea()); + BigDecimal oldVolume = materialInventoryPO.getVolume(); + BigDecimal newVolume = oldVolume.add(shelfMaterialDetail.getTotalVolume()); + BigDecimal oldGrossWeight = materialInventoryPO.getGrossWeight(); + BigDecimal newGrossWeight = oldGrossWeight.add(shelfMaterialDetail.getTotalGrossWeight()); + BigDecimal oldNetWeight = materialInventoryPO.getNetWeight(); + BigDecimal newNetWeight = oldNetWeight.add(shelfMaterialDetail.getTotalNetWeight()); + materialInventoryPO.setInventoryQuantity(newInventoryQuantity); materialInventoryPO.setAllocationQuantity(newAllocationQuantity); + materialInventoryPO.setArea(newArea); + materialInventoryPO.setVolume(newVolume); + materialInventoryPO.setGrossWeight(newGrossWeight); + materialInventoryPO.setNetWeight(newNetWeight); BeanUtils.copyProperties(materialInventoryPO, materialInventory); materialInventory.setUpdateBy(loginUser.getUserid()); materialInventory.setUpdateByName(loginUser.getUsername());