Commit 55bbc352677f11d490d86986203802d640c1e9ee
1 parent
40e0d422
库存修改
Showing
3 changed files
with
4 additions
and
4 deletions
urbanops-module-garden/src/main/java/com/zteits/urbanops/module/garden/service/materialinventory/MaterialInventoryServiceImpl.java
| ... | ... | @@ -99,7 +99,7 @@ public class MaterialInventoryServiceImpl implements MaterialInventoryService { |
| 99 | 99 | @Override |
| 100 | 100 | public int insertMaterialInventory(MaterialInventoryDO materialInventory) { |
| 101 | 101 | LambdaQueryWrapper<MaterialInventoryDO> queryWrapper = Wrappers.lambdaQuery(); |
| 102 | - //queryWrapper.eq(MaterialInventoryDO::getBelongCompanyId, materialInventory.getBelongCompanyId()); | |
| 102 | + queryWrapper.eq(MaterialInventoryDO::getBelongCompanyId, materialInventory.getBelongCompanyId()); | |
| 103 | 103 | queryWrapper.eq(MaterialInventoryDO::getMaterialId, materialInventory.getMaterialId()); |
| 104 | 104 | MaterialInventoryDO object = materialInventoryMapper.selectOne(queryWrapper); |
| 105 | 105 | if(object != null){ | ... | ... |
urbanops-module-garden/src/main/java/com/zteits/urbanops/module/garden/service/materialinventoryin/MaterialInventoryInServiceImpl.java
| ... | ... | @@ -144,7 +144,7 @@ public class MaterialInventoryInServiceImpl implements MaterialInventoryInServic |
| 144 | 144 | if (null == materialInventoryIn) { |
| 145 | 145 | throw exception(MATERIAL_INVENTORY_IN_NOT_EXISTS); |
| 146 | 146 | } |
| 147 | - MaterialInventoryDO inventory = materialInventoryService.selectMaterialInventoryByMaterialId(materialInventoryIn.getMaterialId()); | |
| 147 | + MaterialInventoryDO inventory = materialInventoryService.selectMaterialInventoryByMaterialId(materialInventoryIn.getTypeDetailId(),getCompanyId()); | |
| 148 | 148 | if(null == inventory){ |
| 149 | 149 | throw exception0(BAD_REQUEST.getCode(),"参数错误"); |
| 150 | 150 | } | ... | ... |
urbanops-module-garden/src/main/java/com/zteits/urbanops/module/garden/service/materialinventoryout/MaterialInventoryOutServiceImpl.java
| ... | ... | @@ -53,7 +53,7 @@ public class MaterialInventoryOutServiceImpl implements MaterialInventoryOutServ |
| 53 | 53 | if(null == material){ |
| 54 | 54 | throw exception0(BAD_REQUEST.getCode(), "无效参数-materialId"); |
| 55 | 55 | } |
| 56 | - MaterialInventoryDO materialInventory = materialInventoryService.selectMaterialInventoryByMaterialId(material.getMaterialId()); | |
| 56 | + MaterialInventoryDO materialInventory = materialInventoryService.selectMaterialInventoryByMaterialId(out.getTypeDetailId(),getCompanyId()); | |
| 57 | 57 | if(null == materialInventory){ |
| 58 | 58 | throw exception0(BAD_REQUEST.getCode(),createReqVO.getMaterialName()+"没有库存"); |
| 59 | 59 | } |
| ... | ... | @@ -108,7 +108,7 @@ public class MaterialInventoryOutServiceImpl implements MaterialInventoryOutServ |
| 108 | 108 | throw exception(MATERIAL_INVENTORY_OUT_NOT_EXISTS); |
| 109 | 109 | } |
| 110 | 110 | |
| 111 | - MaterialInventoryDO inventory = materialInventoryService.selectMaterialInventoryByMaterialId(materialInventoryOut.getMaterialId()); | |
| 111 | + MaterialInventoryDO inventory = materialInventoryService.selectMaterialInventoryByMaterialId(materialInventoryOut.getTypeDetailId(),getCompanyId()); | |
| 112 | 112 | if(null == inventory){ |
| 113 | 113 | throw exception0(BAD_REQUEST.getCode(),"参数错误"); |
| 114 | 114 | } | ... | ... |