|
@@ -939,22 +939,22 @@ public class StoreInfoServiceImpl extends ServiceImpl<StoreInfoMapper, StoreInfo
|
|
|
result.setCouponList(quanVoList);
|
|
result.setCouponList(quanVoList);
|
|
|
|
|
|
|
|
// 获取店铺团购
|
|
// 获取店铺团购
|
|
|
- LambdaUpdateWrapper<LifeCoupon> tuangouWrapper = new LambdaUpdateWrapper<>();
|
|
|
|
|
- tuangouWrapper.eq(LifeCoupon::getStoreId, storeId).eq(LifeCoupon::getStatus, 1).eq(LifeCoupon::getType, 2).orderByDesc(LifeCoupon::getCreatedTime);
|
|
|
|
|
- List<LifeCoupon> tuangouList = lifeCouponMapper.selectList(tuangouWrapper);
|
|
|
|
|
- List<LifeCouponVo> tuangouVOList = new ArrayList<>();
|
|
|
|
|
- for (LifeCoupon lifeCoupon : tuangouList) {
|
|
|
|
|
- LifeCouponVo lifeCouponVo = new LifeCouponVo();
|
|
|
|
|
- BeanUtils.copyProperties(lifeCoupon, lifeCouponVo);
|
|
|
|
|
- if (StringUtils.isNotEmpty(lifeCoupon.getImagePath())) {
|
|
|
|
|
- List<String> ids = Arrays.stream(lifeCoupon.getImagePath().split(",")).map(String::trim).collect(Collectors.toList());
|
|
|
|
|
|
|
+ LambdaUpdateWrapper<LifeGroupBuyMain> tuangouWrapper = new LambdaUpdateWrapper<>();
|
|
|
|
|
+ tuangouWrapper.eq(LifeGroupBuyMain::getStoreId, storeId).eq(LifeGroupBuyMain::getStatus, 5).orderByDesc(LifeGroupBuyMain::getCreatedTime);
|
|
|
|
|
+ List<LifeGroupBuyMain> tuangouList = lifeGroupBuyMainMapper.selectList(tuangouWrapper);
|
|
|
|
|
+ List<LifeGroupBuyMainVo> tuangouVOList = new ArrayList<>();
|
|
|
|
|
+ for (LifeGroupBuyMain lifeGroupBuyMain : tuangouList) {
|
|
|
|
|
+ LifeGroupBuyMainVo lifeGroupBuyMainVo = new LifeGroupBuyMainVo();
|
|
|
|
|
+ BeanUtils.copyProperties(lifeGroupBuyMain, lifeGroupBuyMainVo);
|
|
|
|
|
+ if (StringUtils.isNotEmpty(lifeGroupBuyMain.getImageId())) {
|
|
|
|
|
+ List<String> ids = Arrays.stream(lifeGroupBuyMain.getImageId().split(",")).map(String::trim).collect(Collectors.toList());
|
|
|
List<StoreImg> imgList = storeImgMapper.selectList(new LambdaQueryWrapper<StoreImg>().in(StoreImg::getId, ids));
|
|
List<StoreImg> imgList = storeImgMapper.selectList(new LambdaQueryWrapper<StoreImg>().in(StoreImg::getId, ids));
|
|
|
if (imgList != null) {
|
|
if (imgList != null) {
|
|
|
String imgs = imgList.stream().map(StoreImg::getImgUrl).collect(Collectors.joining(","));
|
|
String imgs = imgList.stream().map(StoreImg::getImgUrl).collect(Collectors.joining(","));
|
|
|
- lifeCouponVo.setImgs(imgs);
|
|
|
|
|
|
|
+ lifeGroupBuyMainVo.setImageId(imgs);
|
|
|
}
|
|
}
|
|
|
}
|
|
}
|
|
|
- tuangouVOList.add(lifeCouponVo);
|
|
|
|
|
|
|
+ tuangouVOList.add(lifeGroupBuyMainVo);
|
|
|
}
|
|
}
|
|
|
result.setTuangouList(tuangouVOList);
|
|
result.setTuangouList(tuangouVOList);
|
|
|
|
|
|