From 8853292babb2ad94de4a3207966f1e83b767cd2d Mon Sep 17 00:00:00 2001
From: zhongrj <646384940@qq.com>
Date: Sun, 17 Sep 2023 16:38:34 +0800
Subject: [PATCH] 新增流程节点进程查询接口
---
src/main/java/org/springblade/modules/system/mapper/RoleMapper.xml | 57 +++++++++++++++++++++++++++++++++++++++++++++++++++++++--
1 files changed, 55 insertions(+), 2 deletions(-)
diff --git a/src/main/java/org/springblade/modules/system/mapper/RoleMapper.xml b/src/main/java/org/springblade/modules/system/mapper/RoleMapper.xml
index 7319078..723bf61 100644
--- a/src/main/java/org/springblade/modules/system/mapper/RoleMapper.xml
+++ b/src/main/java/org/springblade/modules/system/mapper/RoleMapper.xml
@@ -21,11 +21,14 @@
</resultMap>
<select id="selectRolePage" resultMap="roleResultMap">
- select * from blade_role where is_deleted = 0
+ select *
+ from blade_role
+ where is_deleted = 0
</select>
<select id="tree" resultMap="treeNodeResultMap">
- select id, parent_id, role_name as title, id as "value", id as "key" from blade_role where is_deleted = 0
+ select id, parent_id, role_name as title, id as "value", id as "key" from blade_role where is_deleted = 0 AND
+ id!=1123598816738675201
<if test="param1!=null">
and tenant_id = #{param1}
</if>
@@ -63,4 +66,54 @@
and is_deleted = 0
</select>
+
+ <select id="Info" resultType="java.lang.String">
+ SELECT role_alias as rolename
+ FROM blade_role
+ WHERE id = #{id}
+ and is_deleted = 0
+ </select>
+
+ <!--角色查询-->
+ <select id="selectRole" resultType="java.util.HashMap">
+ SELECT id,
+ role_name AS title
+ FROM blade_role
+ WHERE is_deleted = 0
+ AND id != 1123598816738675201
+ AND id != 1414575877054365698
+ AND id != 1414840172333842433
+ AND id != 1415870935329771522
+ AND id != 1416733602219110402
+ AND id != 1428177141018771458
+ AND id != 1428972101748465665
+ AND id != 1431234799414071297
+ </select>
+
+ <!--角色查询-->
+ <select id="getRoleList" resultType="org.springblade.modules.system.entity.Role">
+ SELECT br.* FROM blade_role br
+ inner join (
+ SELECT * FROM
+ (
+ SELECT t1.*,IF( find_in_set( parent_id, @pids ) > 0, @pids := concat( @pids, ',', id ), 0 ) AS ischild FROM
+ ( SELECT id, parent_id,role_name,role_alias FROM blade_role t where is_deleted =0 ORDER BY parent_id, id ) t1,
+ ( SELECT @pids := #{roleParam.roleId} ) t2
+ ) t3
+ WHERE id != 1123598816738675201 and id != #{roleParam.roleId}
+ <if test="roleParam.roleName!=null and roleParam.roleName!=''">
+ and role_name like concat('%',#{roleParam.roleName},'%')
+ </if>
+ <if test="roleParam.roleAlias!=null and roleParam.roleAlias!=''">
+ and role_alias like concat('%',#{roleParam.roleAlias},'%')
+ </if>
+ ) t4 on br.id = t4.id
+ <if test="roleParam.isNowLevel==0">
+ union all
+ (
+ SELECT * FROM blade_role where id = #{roleParam.roleId}
+ )
+ </if>
+ </select>
+
</mapper>
--
Gitblit v1.9.3