|
|
|
@ -338,6 +338,7 @@ public class StudentHandsOnTaskVideoService extends CoreBaseService<StudentHands
|
|
|
|
|
StudentHandsOnTaskVideo studentHandsOnTaskVideo = this.sqlManager.lambdaQuery(StudentHandsOnTaskVideo.class).andEq(StudentHandsOnTaskVideo::getHandsOnTaskId, taskId)
|
|
|
|
|
.andEq(StudentHandsOnTaskVideo::getStudentId, student.getStudentId()).singleSimple();
|
|
|
|
|
if (studentHandsOnTaskVideo == null) {
|
|
|
|
|
studentHandsOnTaskVideo = new StudentHandsOnTaskVideo();
|
|
|
|
|
TeacherOpenCourseHandsOnSimulationTasksFileQuery fileQuery = new TeacherOpenCourseHandsOnSimulationTasksFileQuery();
|
|
|
|
|
fileQuery.setTaskId(taskId);
|
|
|
|
|
//查询视频
|
|
|
|
@ -356,12 +357,14 @@ public class StudentHandsOnTaskVideoService extends CoreBaseService<StudentHands
|
|
|
|
|
for (TeacherOpenCourseHandsOnSimulationTasksFile file : videoFile) {
|
|
|
|
|
Map<String, Object> map = new HashMap<>();
|
|
|
|
|
map.put("fileName", file.getFileName());
|
|
|
|
|
map.put("taskFileId", file.getTaskFileId());
|
|
|
|
|
map.put("schedule", 0);
|
|
|
|
|
map.put("fileUrl", file.getFileUrl());
|
|
|
|
|
list.add(map);
|
|
|
|
|
}
|
|
|
|
|
studentHandsOnTaskVideo.setVideoFile(JSONArray.toJSONString(list));
|
|
|
|
|
studentHandsOnTaskVideo.setVideoFiles(list);
|
|
|
|
|
this.insert(studentHandsOnTaskVideo);
|
|
|
|
|
}else {
|
|
|
|
|
String videoFile = studentHandsOnTaskVideo.getVideoFile();
|
|
|
|
|
if (StringUtils.isNotEmpty(videoFile)) {
|
|
|
|
|