|
|
@@ -1394,10 +1394,10 @@ public class InventoryService extends BaseService<Inventory> {
|
|
|
inventoryMapper.updateAmtAndQty(inventory);
|
|
|
|
|
|
//region 采购入库 并且 其他入库编辑传给库存标识 为true 查询库存修改完是否为0,如果为0 将库存制成无效
|
|
|
- if(Constant.InventoryDocCode.OTHER_INBOUND.getValue().equals(inOutRecordVO.getInventoryDocCode()) && inOutRecordVO.getUpdateOtherIntoInvFlag()){
|
|
|
- Inventory inventoryDel = inventoryMapper.selectById(inventory);
|
|
|
+ if (Constant.InventoryDocCode.OTHER_INBOUND.getValue().equals(inOutRecordVO.getInventoryDocCode()) && inOutRecordVO.getUpdateOtherIntoInvFlag() != null && inOutRecordVO.getUpdateOtherIntoInvFlag()) {
|
|
|
+ InventoryResponse inventoryDel = inventoryMapper.selectById(inventory.getInvId());
|
|
|
if(inventoryDel.getInvQty().compareTo(BigDecimal.ZERO)==0){
|
|
|
- inventoryMapper.updateById(new Inventory().setInvId(inventory.getInvId()).setFlgValid(false));
|
|
|
+ inventoryMapper.updateFlgValid(new InventoryVO().setInvId(inventory.getInvId()));
|
|
|
}
|
|
|
}
|
|
|
//endregion
|