From 4f3a98f19143865cdc1de4791e8a95d96bd40c65 Mon Sep 17 00:00:00 2001 From: maven <2163098428@qq.com> Date: 星期五, 01 八月 2025 13:27:59 +0800 Subject: [PATCH] yys 密码已重置 --- cnas-personnel/src/main/resources/mapper/PersonRewardPunishmentRecordMapper.xml | 47 +++++++++++++++++++++++++++++++++++++++++++++++ 1 files changed, 47 insertions(+), 0 deletions(-) diff --git a/cnas-personnel/src/main/resources/mapper/PersonRewardPunishmentRecordMapper.xml b/cnas-personnel/src/main/resources/mapper/PersonRewardPunishmentRecordMapper.xml new file mode 100644 index 0000000..d92a163 --- /dev/null +++ b/cnas-personnel/src/main/resources/mapper/PersonRewardPunishmentRecordMapper.xml @@ -0,0 +1,47 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd"> +<mapper namespace="com.ruoyi.personnel.mapper.PersonRewardPunishmentRecordMapper"> + + + <select id="rewardPunishmentPage" resultType="com.ruoyi.personnel.dto.PersonRewardPunishmentRecordDto"> + select cprpr.*, us.name create_user_name, u.account account, u.name user_name + from cnas_person_reward_punishment_record cprpr + left join user u on cprpr.user_id = u.id + left join user us on cprpr.create_user = us.id + <where> + <if test="userId != null and userId != ''"> + and cprpr.user_id = #{userId} + </if> + <if test="userName != null and userName != ''"> + and u.name like concat('%', #{userName}, '%') + </if> + <if test="startTime != null and endTime != null"> + AND DATE(cprpr.reward_punish_time) BETWEEN #{startTime} AND #{endTime} + </if> + <if test="departmentId != null and departmentId != ''"> + and FIND_IN_SET(#{departmentId}, u.depart_lims_id) + </if> + </where> + </select> + + <select id="rewardPunishmentExport" resultType="com.ruoyi.personnel.excel.PersonRewardPunishmentRecordExcel"> + select cprpr.*, us.name create_user_name, u.account account, u.name user_name + from cnas_person_reward_punishment_record cprpr + left join user u on cprpr.user_id = u.id + left join user us on cprpr.create_user = us.id + <where> + <if test="userId != null and userId != ''"> + and cprpr.user_id = #{userId} + </if> + <if test="departmentId != null and departmentId != ''"> + and FIND_IN_SET(#{departmentId},u.depart_lims_id) + </if> + <if test="userName != null and userName != ''"> + and u.name like concat('%', #{userName}, '%') + </if> + <if test="startTime != null and endTime != null"> + AND DATE(cprpr.reward_punish_time) BETWEEN #{startTime} AND #{endTime} + </if> + </where> + </select> +</mapper> -- Gitblit v1.9.3