From abd73edd5d08e26fba60ab47f53722502a87505a Mon Sep 17 00:00:00 2001
From: zouyu <2723363702@qq.com>
Date: 星期四, 08 一月 2026 17:21:50 +0800
Subject: [PATCH] 浪潮对接单点登录:租户数据隔离功能
---
src/main/resources/mapper/system/SysPostMapper.xml | 6 +++++-
1 files changed, 5 insertions(+), 1 deletions(-)
diff --git a/src/main/resources/mapper/system/SysPostMapper.xml b/src/main/resources/mapper/system/SysPostMapper.xml
index 177f74d..ce16e9f 100644
--- a/src/main/resources/mapper/system/SysPostMapper.xml
+++ b/src/main/resources/mapper/system/SysPostMapper.xml
@@ -19,7 +19,7 @@
<sql id="selectPostVo">
select post_id, post_code, post_name, post_sort, status, create_by, create_time, remark
- from sys_post
+ from sys_post p
</sql>
<select id="selectPostList" parameterType="com.ruoyi.project.system.domain.SysPost" resultMap="SysPostResult">
@@ -34,6 +34,8 @@
<if test="postName != null and postName != ''">
AND post_name like concat('%', #{postName}, '%')
</if>
+ <!-- 鏁版嵁鑼冨洿杩囨护 -->
+ ${params.dataScope}
</where>
</select>
@@ -95,6 +97,7 @@
<if test="status != null and status != ''">status,</if>
<if test="remark != null and remark != ''">remark,</if>
<if test="createBy != null and createBy != ''">create_by,</if>
+ <if test="tenantId != null and tenantId != ''">tenant_id,</if>
create_time
)values(
<if test="postId != null and postId != 0">#{postId},</if>
@@ -104,6 +107,7 @@
<if test="status != null and status != ''">#{status},</if>
<if test="remark != null and remark != ''">#{remark},</if>
<if test="createBy != null and createBy != ''">#{createBy},</if>
+ <if test="tenantId != null and tenantId != ''">#{tenantId},</if>
sysdate()
)
</insert>
--
Gitblit v1.9.3