|
@@ -97,6 +97,7 @@ public class CourseClassHourController {
|
|
|
//添加文件,测验等关联信息
|
|
//添加文件,测验等关联信息
|
|
|
List<CourseRelate> courseRelates = classHourAddParam.getCourseRelates();
|
|
List<CourseRelate> courseRelates = classHourAddParam.getCourseRelates();
|
|
|
courseRelates = courseRelates.stream()
|
|
courseRelates = courseRelates.stream()
|
|
|
|
|
+ .peek(oneCourseRelate -> oneCourseRelate.setChapterhourType("1")) // 修改属性
|
|
|
.peek(oneCourseRelate -> oneCourseRelate.setMainId(classHour.getId())) // 修改属性
|
|
.peek(oneCourseRelate -> oneCourseRelate.setMainId(classHour.getId())) // 修改属性
|
|
|
.collect(Collectors.toList());
|
|
.collect(Collectors.toList());
|
|
|
courseRelateService.addBatch(courseRelates);
|
|
courseRelateService.addBatch(courseRelates);
|
|
@@ -127,6 +128,7 @@ public class CourseClassHourController {
|
|
|
//重新添加关联内容
|
|
//重新添加关联内容
|
|
|
List<CourseRelate> courseRelates = classHourEditParam.getCourseRelates();
|
|
List<CourseRelate> courseRelates = classHourEditParam.getCourseRelates();
|
|
|
courseRelates = courseRelates.stream()
|
|
courseRelates = courseRelates.stream()
|
|
|
|
|
+ .peek(oneCourseRelate -> oneCourseRelate.setChapterhourType("1"))
|
|
|
.peek(oneCourseRelate -> oneCourseRelate.setMainId(classHour.getId())) // 修改属性
|
|
.peek(oneCourseRelate -> oneCourseRelate.setMainId(classHour.getId())) // 修改属性
|
|
|
.collect(Collectors.toList());
|
|
.collect(Collectors.toList());
|
|
|
courseRelateService.addBatch(courseRelates);
|
|
courseRelateService.addBatch(courseRelates);
|
|
@@ -172,7 +174,7 @@ public class CourseClassHourController {
|
|
|
List<String>funcTypeList=CollStreamUtil.toList(relateList, CourseRelate::getFuncType);
|
|
List<String>funcTypeList=CollStreamUtil.toList(relateList, CourseRelate::getFuncType);
|
|
|
Map relateParam =new HashMap();
|
|
Map relateParam =new HashMap();
|
|
|
relateParam.put("mainId", req.getParameter("id"));
|
|
relateParam.put("mainId", req.getParameter("id"));
|
|
|
- relateParam.put("chapterhourType", "0");
|
|
|
|
|
|
|
+ relateParam.put("chapterhourType", "1");
|
|
|
//分别查回视频,讲义,字幕,作业,测验等
|
|
//分别查回视频,讲义,字幕,作业,测验等
|
|
|
for(String oneFunctype:funcTypeList)
|
|
for(String oneFunctype:funcTypeList)
|
|
|
{
|
|
{
|
|
@@ -208,7 +210,7 @@ public class CourseClassHourController {
|
|
|
List<String>funcTypeList=CollStreamUtil.toList(relateList, CourseRelate::getFuncType);
|
|
List<String>funcTypeList=CollStreamUtil.toList(relateList, CourseRelate::getFuncType);
|
|
|
Map relateParam =new HashMap();
|
|
Map relateParam =new HashMap();
|
|
|
relateParam.put("mainId", req.getParameter("id"));
|
|
relateParam.put("mainId", req.getParameter("id"));
|
|
|
- relateParam.put("chapterhourType", "0");
|
|
|
|
|
|
|
+ relateParam.put("chapterhourType", "1");
|
|
|
//分别查回视频,讲义,字幕,作业,测验等
|
|
//分别查回视频,讲义,字幕,作业,测验等
|
|
|
for(String oneFunctype:funcTypeList)
|
|
for(String oneFunctype:funcTypeList)
|
|
|
{
|
|
{
|