| | |
| | | Wrapper<Documentation> queryWrapper = new LambdaQueryWrapper<Documentation>() |
| | | .in(Documentation::getWarehouseGoodsShelvesRowcolId, ids); |
| | | List<Documentation> documentations = documentationMapper.selectList(queryWrapper); |
| | | if (!documentations.isEmpty()) { |
| | | log.error("货架[ID:{}]上存在商品,禁止删除", ids); |
| | | return false; |
| | | } |
| | | int i = warehouseGoodsShelvesRowcolMapper.deleteBatchIds(ids); |
| | | if(i!=ids.size()){ |
| | | log.error("删除失败"); |
| | | return false; |
| | | } |
| | | if (!documentations.isEmpty()) return false; |
| | | warehouseGoodsShelvesRowcolMapper.deleteBatchIds(ids); |
| | | return true; |
| | | } |
| | | } |