|
|
@@ -755,18 +755,10 @@ public class ProductServiceImpl extends ServiceImpl<ProductMapper, Product> impl
|
|
|
public IPage<Product> listProdByCategoryIdAndShopId(ProdByCategoryIdAndShopIdDTO prodByCategoryIdAndShopIdDTO) {
|
|
|
IPage<Product> productIPage = productMapper.listProdByCIdAndSId(new Page<>(prodByCategoryIdAndShopIdDTO.getCurrent(), prodByCategoryIdAndShopIdDTO.getSize()),
|
|
|
prodByCategoryIdAndShopIdDTO);
|
|
|
-// if (productIPage.getRecords().isEmpty()) {
|
|
|
-// productIPage = productMapper.listProdByCategoryIdAndShopId2(new Page<>(prodByCategoryIdAndShopIdDTO.getCurrent(), prodByCategoryIdAndShopIdDTO.getSize()),
|
|
|
-// prodByCategoryIdAndShopIdDTO);
|
|
|
-// }
|
|
|
productIPage.getRecords().forEach(product -> {
|
|
|
-// List<Sku> skus = skuMapper.selectList(Wrappers.<Sku>lambdaQuery().eq(Sku::getProdId, product.getProdId()));
|
|
|
- //TODO wangjian 查询具体的价格
|
|
|
-// product.setSkuList(skus);
|
|
|
List<Sku> skuList = skuMapper.listByProdId(product.getProdId());
|
|
|
product.setSkuList(skuList);
|
|
|
});
|
|
|
-
|
|
|
return productIPage;
|
|
|
}
|
|
|
|