|
@@ -902,15 +902,24 @@ public class StudentRegistrationServiceImpl extends BaseServiceImpl<Long, Studen
|
|
|
@Override
|
|
|
public List<StudentRegistration> findMusicGroupStuNoClassType(String musicGroupId, ClassGroupTypeEnum type, Integer subjectId) {
|
|
|
List<StudentRegistration> students = studentRegistrationDao.findMusicGroupStudent(musicGroupId, subjectId);
|
|
|
+ List<Subject> subjectList = subjectService.findAll(new HashMap<>());
|
|
|
+
|
|
|
List<ClassGroupStudentMapper> classGroupStudentMappers = classGroupStudentMapperDao.findMusicGroupClassGroupByType(musicGroupId, type);
|
|
|
Iterator<StudentRegistration> iterator = students.iterator();
|
|
|
- while (iterator.hasNext()){
|
|
|
+ while (iterator.hasNext()) {
|
|
|
StudentRegistration student = iterator.next();
|
|
|
+ for (Subject subject : subjectList) {
|
|
|
+ if (student.getActualSubjectId().equals(subject.getId())) {
|
|
|
+ student.setSubjectName(subject.getName());
|
|
|
+ }
|
|
|
+ }
|
|
|
+ if (type.equals(ClassGroupTypeEnum.SNAP)) continue;
|
|
|
for (ClassGroupStudentMapper classGroupStudentMapper : classGroupStudentMappers) {
|
|
|
if (student.getUserId().equals(classGroupStudentMapper.getUserId())) {
|
|
|
iterator.remove();
|
|
|
}
|
|
|
}
|
|
|
+
|
|
|
}
|
|
|
return students;
|
|
|
}
|