ソースを参照

报告bug修复

xiaof 4 年 前
コミット
0909941bdb

+ 21 - 0
teachcloud-report-business/src/main/java/com/qmth/teachcloud/report/business/mapper/TBExamStudentMapper.java

@@ -41,6 +41,16 @@ public interface TBExamStudentMapper extends BaseMapper<TBExamStudent> {
      */
     List<TBExamStudentResult> selectInspectCollegeList(@Param("schoolId") Long schoolId, @Param("examId") Long examId, @Param("courseCode") String courseCode);
 
+    /**
+     * 开课课程考试分析-考查学院列表
+     *
+     * @param schoolId
+     * @param examId
+     * @param courseCode
+     * @return
+     */
+    List<TBExamStudentResult> selectInspectCollegeListNotAbsent(@Param("schoolId") Long schoolId, @Param("examId") Long examId, @Param("courseCode") String courseCode);
+
     /**
      * 查询老师列表
      *
@@ -52,6 +62,17 @@ public interface TBExamStudentMapper extends BaseMapper<TBExamStudent> {
      */
     List<TBExamStudentResult> selectTeachList(@Param("schoolId") Long schoolId, @Param("examId") Long examId, @Param("courseCode") String courseCode, @Param("inspectCollegeId") Long inspectCollegeId);
 
+    /**
+     * 开课课程考试分析-查询老师列表
+     *
+     * @param schoolId
+     * @param examId
+     * @param courseCode
+     * @param inspectCollegeId
+     * @return
+     */
+    List<TBExamStudentResult> selectTeachListNotAbsent(@Param("schoolId") Long schoolId, @Param("examId") Long examId, @Param("courseCode") String courseCode, @Param("inspectCollegeId") Long inspectCollegeId);
+
     /**
      * 查询班级列表
      *

+ 21 - 0
teachcloud-report-business/src/main/java/com/qmth/teachcloud/report/business/service/TBExamStudentService.java

@@ -42,6 +42,16 @@ public interface TBExamStudentService extends IService<TBExamStudent> {
      */
     List<TBExamStudentResult> selectInspectCollegeList(Long schoolId, Long examId, String courseCode);
 
+    /**
+     * 开课课程考试分析-考查学院列表
+     *
+     * @param schoolId
+     * @param examId
+     * @param courseCode
+     * @return
+     */
+    List<TBExamStudentResult> selectInspectCollegeListNotAbsent(Long schoolId, Long examId, String courseCode);
+
     /**
      * 查询老师列表
      *
@@ -53,6 +63,17 @@ public interface TBExamStudentService extends IService<TBExamStudent> {
      */
     List<TBExamStudentResult> selectTeachList(Long schoolId, Long examId, String courseCode, Long inspectCollegeId);
 
+    /**
+     * 开课课程考试分析-查询老师列表
+     *
+     * @param schoolId
+     * @param examId
+     * @param courseCode
+     * @param inspectCollegeId
+     * @return
+     */
+    List<TBExamStudentResult> selectTeachListNotAbsent(Long schoolId, Long examId, String courseCode, Long inspectCollegeId);
+
     /**
      * 查询班级列表
      *

+ 27 - 0
teachcloud-report-business/src/main/java/com/qmth/teachcloud/report/business/service/impl/TBExamStudentServiceImpl.java

@@ -109,6 +109,19 @@ public class TBExamStudentServiceImpl extends ServiceImpl<TBExamStudentMapper, T
         return tbExamStudentMapper.selectInspectCollegeList(schoolId, examId, courseCode);
     }
 
+    /**
+     * 开课课程考试分析-考查学院列表
+     *
+     * @param schoolId
+     * @param examId
+     * @param courseCode
+     * @return
+     */
+    @Override
+    public List<TBExamStudentResult> selectInspectCollegeListNotAbsent(Long schoolId, Long examId, String courseCode) {
+        return tbExamStudentMapper.selectInspectCollegeListNotAbsent(schoolId, examId, courseCode);
+    }
+
     /**
      * 查询老师列表
      *
@@ -123,6 +136,20 @@ public class TBExamStudentServiceImpl extends ServiceImpl<TBExamStudentMapper, T
         return tbExamStudentMapper.selectTeachList(schoolId, examId, courseCode, inspectCollegeId);
     }
 
+    /**
+     * 开课课程考试分析-查询老师列表
+     *
+     * @param schoolId
+     * @param examId
+     * @param courseCode
+     * @param inspectCollegeId
+     * @return
+     */
+    @Override
+    public List<TBExamStudentResult> selectTeachListNotAbsent(Long schoolId, Long examId, String courseCode, Long inspectCollegeId) {
+        return tbExamStudentMapper.selectTeachListNotAbsent(schoolId, examId, courseCode, inspectCollegeId);
+    }
+
     /**
      * 查询班级列表
      *

+ 35 - 0
teachcloud-report-business/src/main/resources/mapper/TBExamStudentMapper.xml

@@ -44,6 +44,23 @@
         </where>
     </select>
 
+    <select id="selectInspectCollegeListNotAbsent"
+            resultType="com.qmth.teachcloud.report.business.bean.result.TBExamStudentResult">
+        select
+        DISTINCT tbes.inspect_college_id as inspectCollegeId,
+        so.name as inspectCollegeName,
+        so.code as inspectCollegeCode
+        from
+        t_b_exam_student tbes
+        join sys_org so on
+        so.id = tbes.inspect_college_id
+        <where>
+            <include refid="conditionSql"/>
+            and tbes.absent = false
+            and tbes.student_current = true
+        </where>
+    </select>
+
     <select id="selectTeachList" resultType="com.qmth.teachcloud.report.business.bean.result.TBExamStudentResult">
         select
         DISTINCT tbes.teacher_id as teacherId,
@@ -60,6 +77,24 @@
         </where>
     </select>
 
+    <select id="selectTeachListNotAbsent" resultType="com.qmth.teachcloud.report.business.bean.result.TBExamStudentResult">
+        select
+        DISTINCT tbes.teacher_id as teacherId,
+        su.real_name as teacherName
+        from
+        t_b_exam_student tbes
+        join sys_user su on
+        su.id = tbes.teacher_id
+        <where>
+            <include refid="conditionSql"/>
+            <if test="inspectCollegeId != null and inspectCollegeId != ''">
+                and tbes.inspect_college_id = #{inspectCollegeId}
+            </if>
+            and tbes.absent = false
+            and tbes.student_current = true
+        </where>
+    </select>
+
     <select id="selectClassList" resultType="com.qmth.teachcloud.report.business.bean.result.TBExamStudentResult">
         select
         DISTINCT tbes.clazz_id as clazzId,

+ 19 - 0
teachcloud-report/src/main/java/com/qmth/teachcloud/report/api/SysReportController.java

@@ -111,6 +111,15 @@ public class SysReportController {
         return ResultUtil.ok(tbExamStudentService.selectInspectCollegeList(SystemConstant.convertIdToLong(schoolId), SystemConstant.convertIdToLong(examId), courseCode));
     }
 
+    @ApiOperation(value = "开课课程考试分析-考查学院列表")
+    @RequestMapping(value = "/common/list_inspect_college_not_absent", method = RequestMethod.POST)
+    @ApiResponses({@ApiResponse(code = 200, message = "考生信息", response = TBExamStudentResult.class)})
+    public Result listInspectCollegeNotAbsent(@ApiParam(value = "学校id", required = true) @RequestParam String schoolId,
+                                     @ApiParam(value = "考试id", required = true) @RequestParam String examId,
+                                     @ApiParam(value = "科目编码", required = false) @RequestParam(required = false) String courseCode) {
+        return ResultUtil.ok(tbExamStudentService.selectInspectCollegeListNotAbsent(SystemConstant.convertIdToLong(schoolId), SystemConstant.convertIdToLong(examId), courseCode));
+    }
+
     @ApiOperation(value = "教师列表")
     @RequestMapping(value = "/common/list_teacher", method = RequestMethod.POST)
     @ApiResponses({@ApiResponse(code = 200, message = "考生信息", response = TBExamStudentResult.class)})
@@ -121,6 +130,16 @@ public class SysReportController {
         return ResultUtil.ok(tbExamStudentService.selectTeachList(SystemConstant.convertIdToLong(schoolId), SystemConstant.convertIdToLong(examId), courseCode, Objects.nonNull(inspectCollegeId) ? SystemConstant.convertIdToLong(inspectCollegeId) : null));
     }
 
+    @ApiOperation(value = "开课课程考试分析-教师列表")
+    @RequestMapping(value = "/common/list_teacher_not_absent", method = RequestMethod.POST)
+    @ApiResponses({@ApiResponse(code = 200, message = "考生信息", response = TBExamStudentResult.class)})
+    public Result listTeacherNotAbsent(@ApiParam(value = "学校id", required = true) @RequestParam String schoolId,
+                              @ApiParam(value = "考试id", required = true) @RequestParam String examId,
+                              @ApiParam(value = "科目编码", required = true) @RequestParam String courseCode,
+                              @ApiParam(value = "考查学院id", required = false) @RequestParam(required = false) String inspectCollegeId) {
+        return ResultUtil.ok(tbExamStudentService.selectTeachListNotAbsent(SystemConstant.convertIdToLong(schoolId), SystemConstant.convertIdToLong(examId), courseCode, Objects.nonNull(inspectCollegeId) ? SystemConstant.convertIdToLong(inspectCollegeId) : null));
+    }
+
     @ApiOperation(value = "班级列表")
     @RequestMapping(value = "/common/list_class", method = RequestMethod.POST)
     @ApiResponses({@ApiResponse(code = 200, message = "考生信息", response = TBExamStudentResult.class)})