| | |
| | | .eq(goodsType != null, Goods::getType, goodsType) |
| | | .eq(categoryId != null, Goods::getGoodsCategoryId, categoryId)); |
| | | List<Integer> goodsIds = goodsList.stream().map(Goods::getId).collect(Collectors.toList()); |
| | | if (goodsId != null){ |
| | | goodsIds.add(goodsId); |
| | | if (goodsId == null){ |
| | | return R.ok(); |
| | | } |
| | | |
| | | Page<GoodsBargainPrice> page = goodsBargainPriceService.page(Page.of(pageNum, pageSize), new LambdaQueryWrapper<GoodsBargainPrice>() |
| | | .eq(!CollectionUtils.isEmpty(goodsIds), GoodsBargainPrice::getGoodsId, goodsId) |
| | | .in(!CollectionUtils.isEmpty(goodsIds), GoodsBargainPrice::getGoodsId, goodsIds) |
| | | .eq(auditStatus != null, GoodsBargainPrice::getAuditStatus, auditStatus)); |
| | | |
| | | page.getRecords().forEach(goodsBargainPrice -> goodsList.stream() |