智慧保安后台管理-外网-验收版本
Administrator
2021-11-25 01233bc13663145957c9fcfce94b8eb87fee0714
派遣,考试,公司查询修改
9 files modified
122 ■■■■ changed files
src/main/java/org/springblade/modules/dispatcher/mapper/DispatcherMapper.xml 2 ●●●●● patch | view | raw | blame | history
src/main/java/org/springblade/modules/exam/controller/ExamScoreController.java 4 ●●●● patch | view | raw | blame | history
src/main/java/org/springblade/modules/exam/mapper/ExamScoreMapper.java 2 ●●● patch | view | raw | blame | history
src/main/java/org/springblade/modules/exam/mapper/ExamScoreMapper.xml 26 ●●●● patch | view | raw | blame | history
src/main/java/org/springblade/modules/exam/service/ExamScoreService.java 2 ●●● patch | view | raw | blame | history
src/main/java/org/springblade/modules/exam/service/impl/ExamScoreServiceImpl.java 4 ●●●● patch | view | raw | blame | history
src/main/java/org/springblade/modules/exam/vo/ExamScoreVO.java 5 ●●●●● patch | view | raw | blame | history
src/main/java/org/springblade/modules/information/mapper/InformationMapper.xml 51 ●●●● patch | view | raw | blame | history
src/main/java/org/springblade/modules/social/mapper/SocialMapper.xml 26 ●●●● patch | view | raw | blame | history
src/main/java/org/springblade/modules/dispatcher/mapper/DispatcherMapper.xml
@@ -31,6 +31,8 @@
        on
            si.departmentid = bu.dept_id
        where 1=1
        and bu.is_deleted = 0
        and bu.status = 1
        <if test="dispatcher.dispatcherUnitId!=null">
            and sd.dispatcher_unit_id = #{dispatcher.dispatcherUnitId}
        </if>
src/main/java/org/springblade/modules/exam/controller/ExamScoreController.java
@@ -341,8 +341,8 @@
     * @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);
    public R<IPage<ExamScoreVO>> scorePage(Query query, String deptid, String jurisdiction,String realName) {
        IPage<ExamScoreVO> pages = examScoreService.scorePage(Condition.getPage(query),deptid,jurisdiction,realName);
        return R.data(pages);
    }
src/main/java/org/springblade/modules/exam/mapper/ExamScoreMapper.java
@@ -31,7 +31,7 @@
     * @param page  分页
     * @return
     */
    List<ExamScoreVO> scorePage(IPage page,String deptid,String jurisdiction);
    List<ExamScoreVO> scorePage(IPage page,String deptid,String jurisdiction,String realName);
    /**
     * 自定义分页-模拟考试
src/main/java/org/springblade/modules/exam/mapper/ExamScoreMapper.xml
@@ -221,17 +221,35 @@
        SELECT
            exam.*,
            user.jurisdiction,
            user.dept_id
            user.dept_id,
            user.real_name realName,
            ke.exam_name examName
        FROM
            exam_score exam
        LEFT JOIN blade_user user ON exam.user_id = user.id
        LEFT JOIN blade_user user
        ON exam.user_id = user.id
        left join
        ksxt_exam ke
        on
        ke.id = exam.exam_id
        left join
        sys_information si
        on
        user.dept_id = si.departmentid
        left join
        sys_jurisdiction sj
        on
        sj.id = si.jurisdiction
        WHERE
        1 = 1
        <if test="realName!=null and realName!=''">
            AND user.real_name = #{realName}
        </if>
        <if test="jurisdiction!=null and jurisdiction!='' and jurisdiction!='1372091709474910209'">
            AND user.jurisdiction = #{jurisdiction}
            AND (sj.id = #{jurisdiction} or sj.parent_id = #{jurisdiction})
        </if>
        <if test="deptid!=null and deptid!=''">
                AND user.dept_id = #{deptid}
            AND user.dept_id = #{deptid}
        </if>
    </select>
src/main/java/org/springblade/modules/exam/service/ExamScoreService.java
@@ -28,7 +28,7 @@
     * @param page
     * @return
     */
    IPage<ExamScoreVO> scorePage(IPage<ExamScoreVO> page,String deptid,String jurisdiction);
    IPage<ExamScoreVO> scorePage(IPage<ExamScoreVO> page,String deptid,String jurisdiction,String realName);
    /**
     * 详情
src/main/java/org/springblade/modules/exam/service/impl/ExamScoreServiceImpl.java
@@ -85,8 +85,8 @@
     * @return
     */
    @Override
    public IPage<ExamScoreVO> scorePage(IPage<ExamScoreVO> page,String deptid,String jurisdiction) {
        return page.setRecords(baseMapper.scorePage(page,deptid,jurisdiction));
    public IPage<ExamScoreVO> scorePage(IPage<ExamScoreVO> page,String deptid,String jurisdiction,String realName) {
        return page.setRecords(baseMapper.scorePage(page,deptid,jurisdiction,realName));
    }
    /**
src/main/java/org/springblade/modules/exam/vo/ExamScoreVO.java
@@ -56,4 +56,9 @@
     */
    private Long trainUnitId;
    private String realName;
    private String examName;
}
src/main/java/org/springblade/modules/information/mapper/InformationMapper.xml
@@ -258,7 +258,8 @@
        AND dispatch = 0
        GROUP BY
        dept_id
        ) A ON A.dept_id = H.departmentid
        ) A
        ON A.dept_id = H.departmentid
        LEFT JOIN (
        SELECT
        COUNT( * ) AS lastnum,
@@ -272,9 +273,15 @@
        AND dispatch = 1
        GROUP BY
        dept_id
        ) B ON H.departmentid = B.dept_id where 1=1
        ) B
        ON H.departmentid = B.dept_id
        left join
        sys_jurisdiction sj
        on
        sj.id = H.jurisdiction
        where 1=1
        <if test="jurisdiction!=null and jurisdiction!='' and jurisdiction!='1372091709474910209'">
            and H.jurisdiction = #{jurisdiction}
            and (sj.id = #{jurisdiction} or sj.parent_id = #{jurisdiction})
        </if>
        <if test="deptid!=null and deptid!=''">
            and H.departmentid = #{deptid}
@@ -284,20 +291,38 @@
    <select id="selectSoil" resultType="java.util.HashMap">
        SELECT IFNULL(A.numj, 0) as numj,
        IFNULL(B.numwj, 0) as numz
        FROM (SELECT departmentid, jurisdiction FROM sys_information GROUP BY departmentid, jurisdiction) H
        LEFT JOIN (SELECT COUNT(*) AS numj, dept_id
        FROM
        (
        SELECT departmentid, jurisdiction FROM sys_information GROUP BY departmentid, jurisdiction
        ) H
        LEFT JOIN
        (
        SELECT COUNT(*) AS numj, dept_id
        FROM blade_user
        WHERE soil = 0 AND `status` = 1 AND is_deleted = 0 AND role_id = '1412226235153731586'
        GROUP BY dept_id) A ON A.dept_id = H.departmentid
        LEFT JOIN (SELECT COUNT(*) AS numwj, dept_id FROM blade_user WHERE soil = 1 and `status` = 1 AND is_deleted = 0
        AND role_id = '1412226235153731586' GROUP BY
        dept_id) B
        ON H.departmentid = B.dept_id where 1=1
        GROUP BY dept_id
        ) A
        ON A.dept_id = H.departmentid
        LEFT JOIN
        (
        SELECT COUNT(*) AS numwj, dept_id FROM blade_user
        WHERE soil = 1
        and `status` = 1
        AND is_deleted = 0
        AND role_id = '1412226235153731586'
        GROUP BY dept_id
        ) B
        ON H.departmentid = B.dept_id
        left join
        sys_jurisdiction sj
        on
        sj.id = H.jurisdiction
        where 1=1
        <if test="jurisdiction!=null and jurisdiction!='' and jurisdiction!='1372091709474910209'">
            and (sj.id = #{jurisdiction} or sj.parent_id = #{jurisdiction})
        </if>
        <if test="deptid!=null and deptid!=''">
            and H.departmentid = #{deptid}
        </if>
        <if test="jurisdiction!=null and jurisdiction!='' and jurisdiction!='1372091709474910209'">
            and H.jurisdiction = #{jurisdiction}
        </if>
    </select>
src/main/java/org/springblade/modules/social/mapper/SocialMapper.xml
@@ -24,21 +24,37 @@
    <select id="selectSocialPage" resultMap="socialResultMap">
        SELECT
        s.*,
        distinct u.id,
        u.real_name as realname
        FROM
        blade_user u
        LEFT JOIN
        sys_socil s
        LEFT JOIN blade_user u ON s.namb = u.id where 1=1
        ON
        s.cardid = u.cardid
        left join
        sys_jurisdiction sj
        on
        sj.id = s.jurisdiction
        where 1=1
        and u.is_deleted = 0
        AND u.status = 1
        and u.soil = 0
        AND u.role_id = '1412226235153731586'
        <if test="social.jurisdiction!=null and social.jurisdiction!='' and social.jurisdiction!='1372091709474910209'">
            and (sj.id=#{social.jurisdiction} or sj.parent_id = #{social.jurisdiction})
        </if>
        <if test="social.realname!=null and social.realname!=''">
            and u.real_name like concat(concat('%', #{social.realname}),'%')
        </if>
        <if test="social.cardid!=null and social.cardid!=''">
            and s.cardid like concat(concat('%', #{social.cardid}),'%')
        </if>
        <if test="social.namb!=null and social.namb!=''">
            and s.namb=#{social.namb}
            and s.namb like concat('%',#{social.namb},'%')
        </if>
        <if test="social.deptid!=null and social.deptid!=''">
            and s.deptid=#{social.deptid}
        </if>
        <if test="social.jurisdiction!=null and social.jurisdiction!=''">
            and s.jurisdiction=#{social.jurisdiction}
        </if>
    </select>