vod普通加密

This commit is contained in:
wangjinlei
2024-07-22 09:14:28 +08:00
parent cb72c75760
commit 14a77868cd
6 changed files with 40 additions and 12 deletions

View File

@@ -40,6 +40,8 @@ public class CourseController {
private ShopProductService shopProductService;
@Autowired
private VideoM3u8Dao videoM3u8Dao;
@Autowired
private SpdbUtil spdbUtil;
@RequestMapping("/getCourseList")
@@ -78,6 +80,21 @@ public class CourseController {
return R.ok();
}
@RequestMapping("/cossVod")
public R cossVod(@RequestBody Map<String,Integer> map) throws Exception {
int p = map.get("page");
int l = map.get("limit");
LambdaQueryWrapper<CourseCatalogueChapterVideoEntity> wrapper = new LambdaQueryWrapper<>();
wrapper.eq(CourseCatalogueChapterVideoEntity::getType,1);
Page<CourseCatalogueChapterVideoEntity> courseCatalogueChapterVideoEntityPage = courseCatalogueChapterVideoService.getBaseMapper().selectPage(new Page<>(p, l), wrapper);
for (CourseCatalogueChapterVideoEntity c :courseCatalogueChapterVideoEntityPage.getRecords()){
spdbUtil.vodTranslationM3u8(c.getVideo());
}
return R.ok();
}
@RequestMapping("/getCoursedetail")
public R getCoursedetail(@RequestBody ParamTo param){
CourseEntity course = courseService.getById(param.getId());