新增到课签到时间窗口与迟到签到时间窗口配置,优化教练评分机制(未测试)
This commit is contained in:
+10
-2
@@ -753,8 +753,16 @@ public class GroupCourseService implements IGroupCourseService {
|
||||
}
|
||||
return groupCourseRepository.findByCoachId(coachId)
|
||||
.filter(course -> {
|
||||
// 排除已取消的课程
|
||||
if (course.getStatus() != null && course.getStatus().equals(CourseStatus.CANCELLED.getValue())) {
|
||||
// 排除已软删除的课程
|
||||
if (course.getDeletedAt() != null) {
|
||||
return false;
|
||||
}
|
||||
// 仅检查以下有效状态的课程:0-正常, 3-进行中, 7-教练迟到
|
||||
Long status = course.getStatus();
|
||||
if (status == null ||
|
||||
(!status.equals(CourseStatus.NORMAL.getValue()) &&
|
||||
!status.equals(CourseStatus.IN_PROGRESS.getValue()) &&
|
||||
!status.equals(CourseStatus.COACH_LATE.getValue()))) {
|
||||
return false;
|
||||
}
|
||||
// 排除自身(编辑时)
|
||||
|
||||
Reference in New Issue
Block a user