|
@@ -80,7 +80,7 @@ public class CourseSectionWatchPerServiceImpl extends ServiceImpl<CourseSectionW
|
|
format = format + "&watchPer="+watchPer.getWatchPer();
|
|
format = format + "&watchPer="+watchPer.getWatchPer();
|
|
}
|
|
}
|
|
String s = Base64.encode(format);
|
|
String s = Base64.encode(format);
|
|
- String url = String.format("%s?param=%s",liveHost,s);
|
|
|
|
|
|
+ String url = String.format("%s?param=%s&tenantId=%s",liveHost,s,watchPer.getTenantId());
|
|
vo.setEnCodePC(url);
|
|
vo.setEnCodePC(url);
|
|
vo.setEnCode(url);
|
|
vo.setEnCode(url);
|
|
if (ObjectUtils.isNull(watchPer)){
|
|
if (ObjectUtils.isNull(watchPer)){
|
|
@@ -116,6 +116,17 @@ public class CourseSectionWatchPerServiceImpl extends ServiceImpl<CourseSectionW
|
|
watchVo.setSectionId(bo.getSectionId());
|
|
watchVo.setSectionId(bo.getSectionId());
|
|
watchVo.setGoodsStatus(goods.getGoodsStatus());
|
|
watchVo.setGoodsStatus(goods.getGoodsStatus());
|
|
watchVo.setGoodsName(goods.getGoodsName());
|
|
watchVo.setGoodsName(goods.getGoodsName());
|
|
|
|
+ //获取课程节信息
|
|
|
|
+ CourseSection section = courseSectionService.getById(bo.getSectionId());
|
|
|
|
+ //判断直播是否开始
|
|
|
|
+ if (ObjectUtils.isNotNull(section) && section.getSectionType() == 2){
|
|
|
|
+ if (section.getLiveStartTime() > DateUtils.getNowTime()){
|
|
|
|
+ //直播时间还没到
|
|
|
|
+ watchVo.setCheckStatus(0);
|
|
|
|
+ watchVo.setCheckMsg("直播时间未到,无法观看!");
|
|
|
|
+ return watchVo;
|
|
|
|
+ }
|
|
|
|
+ }
|
|
//获取观看权限
|
|
//获取观看权限
|
|
CourseSectionWatchPer watchPer = getOne(new LambdaQueryWrapper<CourseSectionWatchPer>()
|
|
CourseSectionWatchPer watchPer = getOne(new LambdaQueryWrapper<CourseSectionWatchPer>()
|
|
.eq(CourseSectionWatchPer::getCourseId, bo.getCourseId())
|
|
.eq(CourseSectionWatchPer::getCourseId, bo.getCourseId())
|