From cdb4df5b86eefa7c36e4746b7fc00d7d15b52ce6 Mon Sep 17 00:00:00 2001
From: ZQN <364596817@qq.com>
Date: 星期五, 21 六月 2024 19:53:34 +0800
Subject: [PATCH] 数据权限优化,执法内容添加

---
 project-system/src/main/resources/mapper/system/SysUserMapper.xml |    6 +++---
 1 files changed, 3 insertions(+), 3 deletions(-)

diff --git a/project-system/src/main/resources/mapper/system/SysUserMapper.xml b/project-system/src/main/resources/mapper/system/SysUserMapper.xml
index 0e54a13..9cd4df7 100644
--- a/project-system/src/main/resources/mapper/system/SysUserMapper.xml
+++ b/project-system/src/main/resources/mapper/system/SysUserMapper.xml
@@ -92,7 +92,7 @@
 			AND (u.dept_id = #{deptId} OR u.dept_id IN ( SELECT t.dept_id FROM sys_dept t WHERE find_in_set(#{deptId}, ancestors) ))
 		</if>
 		<!-- 鏁版嵁鑼冨洿杩囨护 -->
-		<if test="params != null and params.dataScope != null">
+		<if test="params != null and params.dataScope != null and params.dataScope != ''">
 			AND ${params.dataScope}
 		</if>
 	</select>
@@ -111,7 +111,7 @@
 			AND u.phonenumber like concat('%', #{phonenumber}, '%')
 		</if>
 		<!-- 鏁版嵁鑼冨洿杩囨护 -->
-		<if test="params != null and params.dataScope != null">
+		<if test="params != null and params.dataScope != null and params.dataScope != ''">
 			AND ${params.dataScope}
 		</if>
 	</select>
@@ -131,7 +131,7 @@
 			AND u.phonenumber like concat('%', #{phonenumber}, '%')
 		</if>
 		<!-- 鏁版嵁鑼冨洿杩囨护 -->
-		<if test="params != null and params.dataScope != null">
+		<if test="params != null and params.dataScope != null and params.dataScope != ''">
 			AND ${params.dataScope}
 		</if>
 	</select>

--
Gitblit v1.9.1