zouxuan 5 年之前
父節點
當前提交
d5b6145b90

+ 7 - 2
mec-biz/src/main/java/com/ym/mec/biz/service/impl/ClassGroupServiceImpl.java

@@ -889,7 +889,6 @@ public class ClassGroupServiceImpl extends BaseServiceImpl<Integer, ClassGroup>
                 break;
             case "PRACTICE":
                 teacherMusicClassGroup = classGroupDao.findTeacherPracticeClassGroup(user.getId().longValue());
-                //获取陪练课学生名称
                 break;
             default:
                 throw new BizException("课程类型错误");
@@ -919,8 +918,14 @@ public class ClassGroupServiceImpl extends BaseServiceImpl<Integer, ClassGroup>
         //统计班级人数
         List<Map<Integer, Integer>> classGroupStudentNumMaps = classGroupStudentMapperDao.countClassGroupsStudentNum(classGroupIds,null);
         Map<Integer, Long> classGroupStudentNumMap = MapUtil.convertIntegerMap(classGroupStudentNumMaps);
-        Map<Integer, Long> currentClassTimes = MapUtil.convertIntegerMap(courseScheduleDao.countCurrentNumByClassGroupId(classGroupIds,user.getId()));
+        Map<Integer, Long> currentClassTimes;
         Map<Integer, Long> noStartClassTimes = MapUtil.convertIntegerMap(courseScheduleDao.countCurrentNumByClassGroupId(classGroupIds,null));
+        if(!type.equals(GroupType.MUSIC)){
+            currentClassTimes = noStartClassTimes;
+        }else {
+            currentClassTimes = MapUtil.convertIntegerMap(courseScheduleDao.countCurrentNumByClassGroupId(classGroupIds,user.getId()));
+        }
+
 
         teacherMusicClassGroup.forEach(teacherClassGroupDto -> {
             if(teacherClassGroupDto.getType() == ClassGroupTypeEnum.PRACTICE){

+ 1 - 1
mec-im/src/main/java/com/ym/config/ResourceServerConfig.java

@@ -10,6 +10,6 @@ import org.springframework.security.oauth2.config.annotation.web.configuration.R
 public class ResourceServerConfig extends ResourceServerConfigurerAdapter {
     @Override
     public void configure(HttpSecurity http) throws Exception {
-        http.authorizeRequests().antMatchers("/v2/api-docs","/user/register","/group/join","/group/create","/room/leave","/room/statusSync").permitAll().anyRequest().authenticated().and().csrf().disable();
+        http.authorizeRequests().antMatchers("/v2/api-docs","/user/register","/group/join","/group/create","/room/leave","/room/statusSync","/group/batchDismiss").permitAll().anyRequest().authenticated().and().csrf().disable();
     }
 }