|
@@ -20,6 +20,7 @@ import com.zhongzheng.modules.goods.domain.Goods;
|
|
|
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.Value;
|
|
|
import org.springframework.stereotype.Service;
|
|
|
|
|
|
import java.util.ArrayList;
|
|
@@ -54,6 +55,9 @@ public class CourseTopicServiceImpl extends ServiceImpl<CourseTopicMapper, Cours
|
|
|
@Autowired
|
|
|
private IWxLoginService wxLoginService;
|
|
|
|
|
|
+ @Value("${liveGotoURL}")
|
|
|
+ private String liveGotoURL;
|
|
|
+
|
|
|
@Override
|
|
|
public CourseTopicVo queryById(Long topicId){
|
|
|
CourseTopic db = this.baseMapper.selectById(topicId);
|
|
@@ -74,9 +78,11 @@ public class CourseTopicServiceImpl extends ServiceImpl<CourseTopicMapper, Cours
|
|
|
lqw.eq( CourseTopic::getStatus, 1);
|
|
|
List<CourseTopicVo> courseTopicVos = entity2Vo(this.list(lqw));
|
|
|
courseTopicVos.forEach(item -> {
|
|
|
- //todo 小程序二维码和PC链接
|
|
|
+ //小程序二维码和PC链接
|
|
|
String enCode = wxLoginService.getTopicEnCode(item.getTopicId());
|
|
|
item.setEnCode(enCode);
|
|
|
+ String url = String.format("%s%s?topicId=%s", liveGotoURL,"goodsTopic",item.getTopicId());
|
|
|
+ item.setEnCodePC(url);
|
|
|
});
|
|
|
return courseTopicVos;
|
|
|
}
|