|
@@ -15,7 +15,9 @@ import org.springframework.beans.factory.annotation.Autowired;
|
|
|
import org.springframework.stereotype.Service;
|
|
|
import org.springframework.util.CollectionUtils;
|
|
|
|
|
|
+import java.util.HashMap;
|
|
|
import java.util.List;
|
|
|
+import java.util.Map;
|
|
|
import java.util.stream.Collectors;
|
|
|
import java.util.stream.Stream;
|
|
|
|
|
@@ -42,7 +44,13 @@ public class ExamTeacherSalaryServiceImpl extends BaseServiceImpl<Long, ExamTeac
|
|
|
if(CollectionUtils.isEmpty(examRooms)){
|
|
|
return;
|
|
|
}
|
|
|
- ExamRoomStudentRelation examRoomStudentRelations = examRoomStudentRelationDao.getExamRoomStudentRelations(examId, null, null);
|
|
|
+ List<ExamRoomStudentRelation> examRoomStudentRelations = examRoomStudentRelationDao.getExamRoomStudentRelations(examId, null, null);
|
|
|
+ Map<Long, List<ExamRoomStudentRelation>> examRoomStudentsMap = new HashMap<>();
|
|
|
+ if(!CollectionUtils.isEmpty(examRoomStudentRelations)){
|
|
|
+ examRoomStudentsMap=examRoomStudentRelations.stream().collect(Collectors.groupingBy(ExamRoomStudentRelation::getExamRoomId));
|
|
|
+ }
|
|
|
+ List<ExamTeacherSalary> examTeacherSalaries = examTeacherSalaryDao.queryWithExam(examId);
|
|
|
+ Map<Integer, ExamTeacherSalary> teacherIdSalaryMap = examTeacherSalaries.stream().collect(Collectors.toMap(ExamTeacherSalary::getTeacherId, e -> e));
|
|
|
|
|
|
}
|
|
|
}
|