智慧保安后台管理-外网-验收版本
zengh
2021-09-10 9c755b34a63b66b4d2b619d30290d79bb7cfdbac
考试详情
5 files modified
59 ■■■■■ changed files
src/main/java/org/springblade/modules/exam/controller/ExamScoreController.java 12 ●●●●● patch | view | raw | blame | history
src/main/java/org/springblade/modules/exam/mapper/ExamScoreMapper.java 8 ●●●●● patch | view | raw | blame | history
src/main/java/org/springblade/modules/exam/mapper/ExamScoreMapper.xml 22 ●●●●● patch | view | raw | blame | history
src/main/java/org/springblade/modules/exam/service/ExamScoreService.java 7 ●●●●● patch | view | raw | blame | history
src/main/java/org/springblade/modules/exam/service/impl/ExamScoreServiceImpl.java 10 ●●●●● patch | view | raw | blame | history
src/main/java/org/springblade/modules/exam/controller/ExamScoreController.java
@@ -334,4 +334,16 @@
        cjhz.put("sccj",sccj);
        return R.data(cjhz);
    }
    /**
     * 自定义分页
     *
     * @param query     page,size
     */
    @GetMapping("/score-page")
    public R<IPage<ExamScoreVO>> scorePage(Query query, String deptid, String jurisdiction) {
        IPage<ExamScoreVO> pages = examScoreService.scorePage(Condition.getPage(query),deptid,jurisdiction);
        return R.data(pages);
    }
}
src/main/java/org/springblade/modules/exam/mapper/ExamScoreMapper.java
@@ -26,6 +26,14 @@
    List<ExamScoreVO> selectExamScorePage(IPage page, @Param("examScore") ExamScoreVO examScore);
    /**
     * 自定义分页
     *
     * @param page  分页
     * @return
     */
    List<ExamScoreVO> scorePage(IPage page,String deptid,String jurisdiction);
    /**
     * 自定义分页-模拟考试
     *
     * @param page  分页
src/main/java/org/springblade/modules/exam/mapper/ExamScoreMapper.xml
@@ -189,7 +189,7 @@
        exam_score exam
        LEFT JOIN blade_user user ON exam.user_id = user.id
        WHERE 1 = 1 AND theory_grade is not null
        <if test="jurisdiction!=null and jurisdiction=='' and jurisdiction!='1123598813738675201'">
        <if test="jurisdiction!=null and jurisdiction!='' and jurisdiction!='1123598813738675201'">
            AND user.jurisdiction = #{jurisdiction}
        </if>
        <if test="deptid!=null and deptid!=''">
@@ -207,7 +207,7 @@
        exam_score exam
        LEFT JOIN blade_user user ON exam.user_id = user.id
        WHERE 1 = 1 AND learn_grade is not null
        <if test="jurisdiction!=null and jurisdiction=='' and jurisdiction!='1123598813738675201'">
        <if test="jurisdiction!=null and jurisdiction!='' and jurisdiction!='1123598813738675201'">
            AND user.jurisdiction = #{jurisdiction}
        </if>
        <if test="deptid!=null and deptid!=''">
@@ -217,6 +217,24 @@
        exam.learn_grade
    </select>
    <select id="scorePage"  resultType="org.springblade.modules.exam.vo.ExamScoreVO">
        SELECT
            exam.*,
            user.jurisdiction,
            user.dept_id
        FROM
            exam_score exam
        LEFT JOIN blade_user user ON exam.user_id = user.id
        WHERE
        1 = 1
        <if test="jurisdiction!=null and jurisdiction!='' and jurisdiction!='1123598813738675201'">
            AND user.jurisdiction = #{jurisdiction}
        </if>
        <if test="deptid!=null and deptid!=''">
                AND user.dept_id = #{deptid}
        </if>
    </select>
    <!--根据用户身份证号查询考试成绩-->
    <select id="getExamScoreInfoByIdCardNo" resultType="org.springblade.modules.exam.entity.ExamScore">
        select
src/main/java/org/springblade/modules/exam/service/ExamScoreService.java
@@ -24,6 +24,13 @@
    IPage<ExamScoreVO> selectExamScorePage(IPage<ExamScoreVO> page, ExamScoreVO examScore);
    /**
     * 自定义分页
     * @param page
     * @return
     */
    IPage<ExamScoreVO> scorePage(IPage<ExamScoreVO> page,String deptid,String jurisdiction);
    /**
     * 详情
     * @param examScore 考试成绩信息对象
     * @return
src/main/java/org/springblade/modules/exam/service/impl/ExamScoreServiceImpl.java
@@ -80,6 +80,16 @@
    }
    /**
     * 自定义分页数据
     * @param page 分页条件
     * @return
     */
    @Override
    public IPage<ExamScoreVO> scorePage(IPage<ExamScoreVO> page,String deptid,String jurisdiction) {
        return page.setRecords(baseMapper.scorePage(page,deptid,jurisdiction));
    }
    /**
     * 详情
     * @param examScore 考试成绩信息对象
     */