|
@@ -18,6 +18,7 @@ import com.zhongzheng.modules.course.vo.CourseTopicGoodsVo;
|
|
|
import com.zhongzheng.modules.course.vo.CourseTopicVo;
|
|
import com.zhongzheng.modules.course.vo.CourseTopicVo;
|
|
|
import com.zhongzheng.modules.goods.domain.Goods;
|
|
import com.zhongzheng.modules.goods.domain.Goods;
|
|
|
import com.zhongzheng.modules.goods.service.IGoodsService;
|
|
import com.zhongzheng.modules.goods.service.IGoodsService;
|
|
|
|
|
+import com.zhongzheng.modules.wx.service.IWxLoginService;
|
|
|
import org.springframework.beans.factory.annotation.Autowired;
|
|
import org.springframework.beans.factory.annotation.Autowired;
|
|
|
import org.springframework.stereotype.Service;
|
|
import org.springframework.stereotype.Service;
|
|
|
|
|
|
|
@@ -50,6 +51,9 @@ public class CourseTopicServiceImpl extends ServiceImpl<CourseTopicMapper, Cours
|
|
|
@Autowired
|
|
@Autowired
|
|
|
private IGoodsService iGoodsService;
|
|
private IGoodsService iGoodsService;
|
|
|
|
|
|
|
|
|
|
+ @Autowired
|
|
|
|
|
+ private IWxLoginService wxLoginService;
|
|
|
|
|
+
|
|
|
@Override
|
|
@Override
|
|
|
public CourseTopicVo queryById(Long topicId){
|
|
public CourseTopicVo queryById(Long topicId){
|
|
|
CourseTopic db = this.baseMapper.selectById(topicId);
|
|
CourseTopic db = this.baseMapper.selectById(topicId);
|
|
@@ -69,7 +73,11 @@ public class CourseTopicServiceImpl extends ServiceImpl<CourseTopicMapper, Cours
|
|
|
lqw.eq(bo.getType() != null, CourseTopic::getType, bo.getType());
|
|
lqw.eq(bo.getType() != null, CourseTopic::getType, bo.getType());
|
|
|
lqw.eq( CourseTopic::getStatus, 1);
|
|
lqw.eq( CourseTopic::getStatus, 1);
|
|
|
List<CourseTopicVo> courseTopicVos = entity2Vo(this.list(lqw));
|
|
List<CourseTopicVo> courseTopicVos = entity2Vo(this.list(lqw));
|
|
|
- //todo 小程序二维码和PC链接
|
|
|
|
|
|
|
+ courseTopicVos.forEach(item -> {
|
|
|
|
|
+ //todo 小程序二维码和PC链接
|
|
|
|
|
+ String enCode = wxLoginService.getTopicEnCode(item.getTopicId());
|
|
|
|
|
+ item.setEnCode(enCode);
|
|
|
|
|
+ });
|
|
|
return courseTopicVos;
|
|
return courseTopicVos;
|
|
|
}
|
|
}
|
|
|
|
|
|