上架库存修改;

This commit is contained in:
王奎兴
2026-04-27 18:58:40 +08:00
parent 1ea3f13a99
commit 71e4188622
@@ -868,10 +868,10 @@ public class MaterialInventoryImpl extends ServiceImpl<MaterialInventoryMapper,
BigDecimal oldFreezeQuantity = materialInventoryPO.getFreezeQuantity();
oldFreezeQuantity = oldFreezeQuantity != null ? oldFreezeQuantity : BigDecimal.ZERO;
//扣减后库存数量
BigDecimal newInventoryQuantity = oldInventoryQuantity.subtract(quantity);
BigDecimal newInventoryQuantity = oldInventoryQuantity.add(quantity);
//扣减后可用数量
BigDecimal newAllocationQuantity = oldAllocationQuantity.subtract(quantity);
BigDecimal newFreezeQuantity = oldFreezeQuantity.subtract(quantity);
BigDecimal newAllocationQuantity = oldAllocationQuantity.add(quantity);
BigDecimal newFreezeQuantity = oldFreezeQuantity.add(quantity);
@@ -892,7 +892,7 @@ public class MaterialInventoryImpl extends ServiceImpl<MaterialInventoryMapper,
BigDecimal newNetWeight = oldNetWeight.add(netWeight);
materialInventoryPO.setInventoryQuantity(newInventoryQuantity);
//materialInventoryPO.setAllocationQuantity(materialInventoryPO.getAllocationQuantity());
materialInventoryPO.setAllocationQuantity(newAllocationQuantity);
materialInventoryPO.setFreezeQuantity(newFreezeQuantity);
materialInventoryPO.setArea(newArea);
materialInventoryPO.setVolume(newVolume);