Browse Source

学生提交申请信息V7.3

平常心 6 months ago
parent
commit
0e3c226fce

+ 5 - 6
yudao-module-as/yudao-module-as-biz/src/main/java/cn/iocoder/yudao/module/as/controller/admin/aidingstudentspersonmanage/vo/AidingStudentPersonManageInfoRespVO.java

@@ -104,15 +104,14 @@ public class AidingStudentPersonManageInfoRespVO {
     private Integer collegeEdit;
     // 已经通过人数
     private Integer collegePass;
-    // TODO 待民主评议班级数量
-
-    // TODO 已经评议班级数量
-
-    // TODO 各班项目进度:?根据提交人数跟通过审批的比列不就是进度?
+    // 待民主评议班级数量
+    private Integer waitingForEvaluationNumber;
+    // 已经评议班级数量
+    private Integer doneEvaluationNumber;
     // 各个班级封装的信息
     private List<AidingStudentPersonManageClassVO> list;
 
-    // TODO 往年申请人数、审批通过人数
+    // TODO 往年申请人数、审批通过人数(没有项目编号跟学院项目编号,不太好找)
 
     /**
      * 学校

+ 0 - 1
yudao-module-as/yudao-module-as-biz/src/main/java/cn/iocoder/yudao/module/as/dal/dataobject/aidingstudentspersonmanage/AidingStudentsPersonManageDO.java

@@ -6,7 +6,6 @@ import com.baomidou.mybatisplus.annotation.TableId;
 import com.baomidou.mybatisplus.annotation.TableName;
 import lombok.*;
 
-import java.time.LocalDateTime;
 
 /**
  * 学生上传申请材料相关信息

+ 13 - 0
yudao-module-as/yudao-module-as-biz/src/main/java/cn/iocoder/yudao/module/as/service/aidingstudentspersonmanage/AidingStudentsPersonManageServiceImpl.java

@@ -123,6 +123,7 @@ public class AidingStudentsPersonManageServiceImpl extends ServiceImpl<AidingStu
             AidingStudentPersonManageInfoPageReqVO pageReqVO) {
         AidingStudentPersonManageInfoRespVO vo = new AidingStudentPersonManageInfoRespVO();
         List<AidingStudentPersonManageClassVO> list = new ArrayList<>();
+        // 1.模糊查询
         List<AidingStudentsPersonManageDO> allList = aidingStudentsPersonManageMapper
                 .selectList(new LambdaQueryWrapper<AidingStudentsPersonManageDO>()
                         .eq(AidingStudentsPersonManageDO::getCollegeManageId, pageReqVO.getCollegeManageId())
@@ -130,6 +131,7 @@ public class AidingStudentsPersonManageServiceImpl extends ServiceImpl<AidingStu
                         .like(StringUtils.isNotBlank(pageReqVO.getMajor()), AidingStudentsPersonManageDO::getMajor, pageReqVO.getMajor())
                         .like(StringUtils.isNotBlank(pageReqVO.getGrade()), AidingStudentsPersonManageDO::getGrade, pageReqVO.getGrade())
                         .like(StringUtils.isNotBlank(pageReqVO.getClassName()), AidingStudentsPersonManageDO::getClassName, pageReqVO.getClassName()));
+        // 2.统计学院学生信息状态
         int wait = 0, edit = 0, pass = 0;
         for (int i = 0; i < allList.size(); i++) {
             AidingStudentsPersonManageDO aDo = allList.get(i);
@@ -147,8 +149,17 @@ public class AidingStudentsPersonManageServiceImpl extends ServiceImpl<AidingStu
         vo.setCollegeAudit(wait);
         vo.setCollegeEdit(edit);
         vo.setCollegePass(pass);
+        // 3.查看班级数量
         List<Map<String, Object>> maps = aidingStudentsPersonManageMapper
                 .countByClassName(pageReqVO);
+        // 3.1 各班民主评议情况
+        List<AidingStudentPersonManageEvaluationResultDO> reviewList = aidingStudentPersonManageEvaluationResultMapper
+                .selectList(new LambdaQueryWrapper<AidingStudentPersonManageEvaluationResultDO>()
+                        .eq(AidingStudentPersonManageEvaluationResultDO::getCollegeManageId, pageReqVO.getCollegeManageId())
+                        .eq(AidingStudentPersonManageEvaluationResultDO::getManageId, pageReqVO.getManageId()));
+        vo.setDoneEvaluationNumber(reviewList.size());
+        vo.setWaitingForEvaluationNumber(maps.size() - reviewList.size() );
+        // 3.2 统计各个班级完成的情况
         for (Map<String, Object> map : maps) {
             AidingStudentPersonManageClassVO classVo = new AidingStudentPersonManageClassVO();
             List<AidingStudentsPersonManageDO> classList = aidingStudentsPersonManageMapper
@@ -177,6 +188,8 @@ public class AidingStudentsPersonManageServiceImpl extends ServiceImpl<AidingStu
             classVo.setClassPass(pass);
             list.add(classVo);
         }
+
+        // 4.封装返回
         vo.setList(list);
         Long total = Long.valueOf(list.size());
         List<AidingStudentPersonManageInfoRespVO> Tlist = new ArrayList<>();