|
@@ -6434,11 +6434,14 @@ public class CourseScheduleServiceImpl extends BaseServiceImpl<Long, CourseSched
|
|
|
// 关联直播间编号
|
|
|
courseScheduleDao.batchUpdateLiveRoomId(collect, finalCourseSchedule.getLiveRoomId());
|
|
|
|
|
|
- collect = newCourseSchedules.subList(0, newCourseSchedules.size() - 1).stream()
|
|
|
- .map(CourseSchedule::getId)
|
|
|
- .distinct().collect(Collectors.toList());
|
|
|
- // 更新连堂课状态
|
|
|
- courseScheduleDao.batchUpdateContinuousCourse(collect, true);
|
|
|
+ if (CollectionUtils.size(collect) > 1) {
|
|
|
+ collect = newCourseSchedules.subList(0, newCourseSchedules.size() - 1).stream()
|
|
|
+ .map(CourseSchedule::getId)
|
|
|
+ .distinct().collect(Collectors.toList());
|
|
|
+
|
|
|
+ // 更新连堂课状态
|
|
|
+ courseScheduleDao.batchUpdateContinuousCourse(collect, true);
|
|
|
+ }
|
|
|
|
|
|
} catch (Exception e) {
|
|
|
log.error("getLiveCourseScheduleTime courseScheduleIds={}", collect, e);
|