|
|
|
@ -1,7 +1,7 @@
|
|
|
|
|
<?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">
|
|
|
|
|
PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
|
|
|
"http://mybatis.org/dtd/mybatis-3-mapper.dtd">
|
|
|
|
|
<mapper namespace="com.ruoyi.system.mapper.SysMenuMapper">
|
|
|
|
|
|
|
|
|
|
<resultMap type="SysMenu" id="SysMenuResult">
|
|
|
|
@ -29,7 +29,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
|
|
|
</sql>
|
|
|
|
|
|
|
|
|
|
<select id="selectMenusByUserId" parameterType="Long" resultMap="SysMenuResult">
|
|
|
|
|
select distinct m.menu_id, m.parent_id, m.menu_name, m.url, m.perms, m.target, m.menu_type, m.icon, m.order_num, m.create_time
|
|
|
|
|
select distinct m.menu_id, m.parent_id, m.menu_name, m.url, m.visible, ifnull(m.perms,'') as perms, m.target, m.menu_type, m.icon, m.order_num, m.create_time
|
|
|
|
|
from sys_menu m
|
|
|
|
|
left join sys_role_menu rm on m.menu_id = rm.menu_id
|
|
|
|
|
left join sys_user_role ur on rm.role_id = ur.role_id
|
|
|
|
@ -39,7 +39,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
|
|
|
</select>
|
|
|
|
|
|
|
|
|
|
<select id="selectMenuNormalAll" resultMap="SysMenuResult">
|
|
|
|
|
select distinct m.menu_id, m.parent_id, m.menu_name, m.url, m.perms, m.target, m.menu_type, m.icon, m.order_num, m.create_time
|
|
|
|
|
select distinct m.menu_id, m.parent_id, m.menu_name, m.url, m.visible, ifnull(m.perms,'') as perms, m.target, m.menu_type, m.icon, m.order_num, m.create_time
|
|
|
|
|
from sys_menu m
|
|
|
|
|
where m.menu_type in ('M', 'C') and m.visible = 0
|
|
|
|
|
order by m.parent_id, m.order_num
|
|
|
|
@ -51,7 +51,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
|
|
|
</select>
|
|
|
|
|
|
|
|
|
|
<select id="selectMenuAllByUserId" parameterType="Long" resultMap="SysMenuResult">
|
|
|
|
|
select distinct m.menu_id, m.parent_id, m.menu_name, m.url, m.perms, m.target, m.menu_type, m.icon, m.order_num, m.create_time
|
|
|
|
|
select distinct m.menu_id, m.parent_id, m.menu_name, m.url, m.visible, ifnull(m.perms,'') as perms, m.target, m.menu_type, m.icon, m.order_num, m.create_time
|
|
|
|
|
from sys_menu m
|
|
|
|
|
left join sys_role_menu rm on m.menu_id = rm.menu_id
|
|
|
|
|
left join sys_user_role ur on rm.role_id = ur.role_id
|
|
|
|
@ -90,7 +90,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
|
|
|
</select>
|
|
|
|
|
|
|
|
|
|
<select id="selectMenuListByUserId" parameterType="SysMenu" resultMap="SysMenuResult">
|
|
|
|
|
select distinct m.menu_id, m.parent_id, m.menu_name, m.url, m.perms, m.target, m.menu_type, m.icon, m.order_num, m.create_time
|
|
|
|
|
select distinct m.menu_id, m.parent_id, m.menu_name, m.url, m.visible, ifnull(m.perms,'') as perms, m.target, m.menu_type, m.icon, m.order_num, m.create_time
|
|
|
|
|
from sys_menu m
|
|
|
|
|
left join sys_role_menu rm on m.menu_id = rm.menu_id
|
|
|
|
|
left join sys_user_role ur on rm.role_id = ur.role_id
|
|
|
|
|