From 4f3a98f19143865cdc1de4791e8a95d96bd40c65 Mon Sep 17 00:00:00 2001
From: maven <2163098428@qq.com>
Date: 星期五, 01 八月 2025 13:27:59 +0800
Subject: [PATCH] yys 密码已重置

---
 ruoyi-system/src/main/resources/mapper/system/UserMapper.xml |  101 ++++++++++++++++++++++++++++++++++++++++++++++++++
 1 files changed, 101 insertions(+), 0 deletions(-)

diff --git a/ruoyi-system/src/main/resources/mapper/system/UserMapper.xml b/ruoyi-system/src/main/resources/mapper/system/UserMapper.xml
new file mode 100644
index 0000000..e3a4e6e
--- /dev/null
+++ b/ruoyi-system/src/main/resources/mapper/system/UserMapper.xml
@@ -0,0 +1,101 @@
+<?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.system.mapper.UserMapper">
+
+    <!--鏍规嵁鏉′欢鑾峰彇鐢ㄦ埛鍒楄〃-->
+    <select id="selectUserCondition" resultType="com.ruoyi.common.core.domain.entity.User">
+        select * from (select id,
+        dept_id,
+        account,
+        name,
+        name_en,
+        user_type,
+        email,
+        phone,
+        sex,
+        age,
+        signature_url,
+        picture_url,
+        status,
+        del_flag,
+        login_ip,
+        login_date,
+        depart_lims_id,
+        company,
+        is_custom
+        from user
+        where del_flag = '0'
+        and id != 1) a
+        <if test="ew.customSqlSegment != null and ew.customSqlSegment != ''">
+            ${ew.customSqlSegment}
+        </if>
+    </select>
+
+    <!-- 鑾峰彇鐢ㄦ埛閮ㄩ棬 -->
+    <select id="selectUserDepartmentLimsName" resultType="java.lang.String">
+        select dl.name
+        from user u
+                 left join department_lims dl on find_in_set(dl.id, u.depart_lims_id) and dl.id != 1
+        where u.id = #{userId}
+        limit 1
+    </select>
+
+    <!-- 鏌ヨ鐢ㄦ埛鍜岄儴闂� -->
+    <select id="selectNameAnddepartment" resultType="java.util.Map">
+        select u.name  userName,
+               dl.name department
+        from user u
+                 left join department_lims dl on find_in_set(dl.id, u.depart_lims_id) and dl.id != 1
+        where find_in_set(u.id, #{participant})
+    </select>
+
+    <!-- 鑾峰彇褰撳墠鐧诲綍鐢ㄦ埛淇℃伅 -->
+    <select id="getUserNow" resultType="com.ruoyi.system.domain.vo.UserVo">
+        select u.id,
+               c.company,
+               u.name,
+               c.code,
+               u.phone,
+               c.id departId
+        from user u
+                 left join custom c on u.company = c.id
+        where u.id = #{userId}
+    </select>
+
+    <!-- 鑾峰彇妫�娴嬩汉鍛樹俊鎭� -->
+    <select id="selectQualityUserList" resultType="com.ruoyi.common.core.domain.entity.User">
+        select u1.id,
+               u1.account,
+               u1.name,
+               u1.age,
+               u1.email,
+               u1.phone,
+               u1.company,
+               u1.is_custom,
+               u1.signature_url,
+               u1.picture_url,
+               u1.name_en,
+               u1.depart_lims_id
+        from user u1
+                 left join sys_user_role sur on sur.user_id = u1.id
+        where sur.role_id not in (1, 15, 16, 17)
+          and u1.status = '0'
+        group by u1.id
+    </select>
+
+    <!-- 鑾峰彇褰撳墠鐧诲綍鐢ㄦ埛閮ㄩ棬涓嬬殑鎵�鏈夌敤鎴� -->
+    <select id="selectDepartmentLimsUserList" resultType="com.ruoyi.common.core.domain.entity.User">
+        select id,
+               account,
+               name,
+               name_en,
+               status
+        from user u
+        where depart_lims_id is not null
+          and depart_lims_id != ''
+          and depart_lims_id = (select u2.depart_lims_id
+                                from user u2
+                                where u2.id = #{userId})
+    </select>
+
+</mapper>

--
Gitblit v1.9.3