|
@@ -2,15 +2,31 @@ package com.keao.edu.user.service.impl;
|
|
|
|
|
|
import com.keao.edu.common.dal.BaseDAO;
|
|
|
import com.keao.edu.common.service.impl.BaseServiceImpl;
|
|
|
+import com.keao.edu.user.api.entity.ExamRoom;
|
|
|
+import com.keao.edu.user.dao.ExamRoomDao;
|
|
|
+import com.keao.edu.user.dao.ExamRoomStudentRelationDao;
|
|
|
import com.keao.edu.user.dao.ExamTeacherSalaryDao;
|
|
|
+import com.keao.edu.user.dao.ExaminationBasicDao;
|
|
|
import com.keao.edu.user.entity.ExamTeacherSalary;
|
|
|
import com.keao.edu.user.service.ExamTeacherSalaryService;
|
|
|
+import com.keao.edu.user.service.ExaminationBasicService;
|
|
|
import org.springframework.beans.factory.annotation.Autowired;
|
|
|
import org.springframework.stereotype.Service;
|
|
|
+import org.springframework.util.CollectionUtils;
|
|
|
+
|
|
|
+import java.util.List;
|
|
|
+import java.util.stream.Collectors;
|
|
|
+import java.util.stream.Stream;
|
|
|
|
|
|
@Service
|
|
|
public class ExamTeacherSalaryServiceImpl extends BaseServiceImpl<Long, ExamTeacherSalary> implements ExamTeacherSalaryService {
|
|
|
-
|
|
|
+
|
|
|
+ @Autowired
|
|
|
+ private ExaminationBasicDao examinationBasicDao;
|
|
|
+ @Autowired
|
|
|
+ private ExamRoomDao examRoomDao;
|
|
|
+ @Autowired
|
|
|
+ private ExamRoomStudentRelationDao examRoomStudentRelationDao;
|
|
|
@Autowired
|
|
|
private ExamTeacherSalaryDao examTeacherSalaryDao;
|
|
|
|
|
@@ -18,5 +34,13 @@ public class ExamTeacherSalaryServiceImpl extends BaseServiceImpl<Long, ExamTeac
|
|
|
public BaseDAO<Long, ExamTeacherSalary> getDAO() {
|
|
|
return examTeacherSalaryDao;
|
|
|
}
|
|
|
-
|
|
|
+
|
|
|
+ @Override
|
|
|
+ public void teacherSalarySettlementWithExam(Integer examId) {
|
|
|
+ List<ExamRoom> examRooms = examRoomDao.getWithExam(null, examId);
|
|
|
+ if(CollectionUtils.isEmpty(examRooms)){
|
|
|
+ return;
|
|
|
+ }
|
|
|
+ List<Long> roomIds = examRooms.stream().map(ExamRoom::getId).collect(Collectors.toList());
|
|
|
+ }
|
|
|
}
|