智慧保安后台管理-外网项目备份
Administrator
2021-09-29 7c9742190965b22f4ea3864aa8588fad19e0be58
src/main/java/org/springblade/modules/exam/mapper/ExamPaperMapper.xml
@@ -101,9 +101,19 @@
    <select id="selectExamPaperPage" resultType="org.springblade.modules.exam.vo.ExamPaperVO">
        SELECT
            *
            ke.*,
            bu.real_name realName,
            bd.dept_name deptName
        FROM
            ksxt_exam
            ksxt_exam ke
        left join
            blade_user bu
        on
            ke.creator = bu.id
        left join
            blade_dept bd
        on
            bd.id = bu.dept_id
        where
        1=1
        <if test="paper.examType!=null and paper.examType!=''">
@@ -111,6 +121,9 @@
        </if>
        <if test="paper.examName!=null and paper.examName!=''">
            and exam_name like concat('%',#{paper.examName},'%')
        </if>
        <if test="paper.deptId!=null and paper.deptId!=''">
            and bd.id = #{paper.deptId}
        </if>
        <if test="paper.auditStatus!=null and paper.auditStatus!=''">
            and audit_status = #{paper.auditStatus}
@@ -198,13 +211,10 @@
        )
    </select>
    <!--查询前缀相同的准考证数量-->
    <!--查询是当前前缀已生成准考证号码最大的一位-->
    <select id="getCandidateNoCount" resultType="java.lang.Integer">
        select count(*) from sys_training_registration
        where 1=1
        <if test="result!=null and result!=''">
            and candidate_no like concat('%', #{result},'%')
        </if>
        select ifnull(max(0+RIGHT(candidate_no,4)),0) from sys_training_registration
        where candidate_no like concat('%', #{result},'%')
    </select>
    <!--查询当前考试已报名的人员培训报名数据集合-->