|
|
@@ -76,7 +76,7 @@ public class BaseStudentSchoolRollServiceImpl extends MPJBaseServiceImpl<BaseStu
|
|
|
new QueryWrapper<BaseClass>().lambda().eq(BaseClass::getTeacherId, teacherId)
|
|
|
);
|
|
|
|
|
|
- if(classList != null && !classList.isEmpty()){
|
|
|
+ if (classList != null && !classList.isEmpty()) {
|
|
|
dto.setTeacherId(teacherId);
|
|
|
}
|
|
|
|
|
|
@@ -86,22 +86,39 @@ public class BaseStudentSchoolRollServiceImpl extends MPJBaseServiceImpl<BaseStu
|
|
|
BaseStudentInfoPageDataVo result = new BaseStudentInfoPageDataVo();
|
|
|
for (BaseStudentInfoCategoryVo categoryVo : genderCount) {
|
|
|
totalCount = totalCount + categoryVo.getNumber();
|
|
|
- if("男".equals(GenderDictionaryEnum.getValue(categoryVo.getCategory()))){
|
|
|
+ if ("男".equals(GenderDictionaryEnum.getValue(categoryVo.getCategory()))) {
|
|
|
result.setMaleCount(categoryVo.getNumber());
|
|
|
- }else if("女".equals(GenderDictionaryEnum.getValue(categoryVo.getCategory()))){
|
|
|
+ } else if ("女".equals(GenderDictionaryEnum.getValue(categoryVo.getCategory()))) {
|
|
|
result.setFemaleCount(categoryVo.getNumber());
|
|
|
}
|
|
|
}
|
|
|
result.setTotalCount(totalCount);
|
|
|
List<BaseStudentInfoCategoryVo> studyStatusCount = baseStudentSchoolRollMapper.getStudyStatusCount(dto);
|
|
|
+ int stayCount = 0;
|
|
|
+ int notStayCount = 0;
|
|
|
for (BaseStudentInfoCategoryVo categoryVo : studyStatusCount) {
|
|
|
- if(StudyStatusEnum.InResidence.getCode().equals(categoryVo.getCategory())){
|
|
|
- result.setStayCount(categoryVo.getNumber());
|
|
|
- }else if(StudyStatusEnum.AttendDaySchool.getCode().equals(categoryVo.getCategory())){
|
|
|
- result.setNotStayCount(categoryVo.getNumber());
|
|
|
+ if (StudyStatusEnum.InResidence.getCode().equals(categoryVo.getCategory())) {
|
|
|
+ stayCount = stayCount + categoryVo.getNumber();
|
|
|
+
|
|
|
+ if ("男".equals(GenderDictionaryEnum.getValue(categoryVo.getCategory()))) {
|
|
|
+ result.setMaleStayCount(categoryVo.getNumber());
|
|
|
+ } else if ("女".equals(GenderDictionaryEnum.getValue(categoryVo.getCategory()))) {
|
|
|
+ result.setFemaleStayCount(categoryVo.getNumber());
|
|
|
+ }
|
|
|
+
|
|
|
+ } else if (StudyStatusEnum.AttendDaySchool.getCode().equals(categoryVo.getCategory())) {
|
|
|
+ notStayCount = notStayCount + categoryVo.getNumber();
|
|
|
+
|
|
|
+ if ("男".equals(GenderDictionaryEnum.getValue(categoryVo.getCategory()))) {
|
|
|
+ result.setMaleNotStayCount(categoryVo.getNumber());
|
|
|
+ } else if ("女".equals(GenderDictionaryEnum.getValue(categoryVo.getCategory()))) {
|
|
|
+ result.setFemaleNotStayCount(categoryVo.getNumber());
|
|
|
+ }
|
|
|
}
|
|
|
}
|
|
|
-
|
|
|
+ result.setStayCount(stayCount);
|
|
|
+ result.setNotStayCount(notStayCount);
|
|
|
+
|
|
|
return result;
|
|
|
}
|
|
|
}
|