diff --git a/ruoyi-common/src/main/java/com/ruoyi/common/core/domain/entity/SysMenu.java b/ruoyi-common/src/main/java/com/ruoyi/common/core/domain/entity/SysMenu.java index e07e6b94..9983ed1a 100644 --- a/ruoyi-common/src/main/java/com/ruoyi/common/core/domain/entity/SysMenu.java +++ b/ruoyi-common/src/main/java/com/ruoyi/common/core/domain/entity/SysMenu.java @@ -66,6 +66,17 @@ public class SysMenu extends BaseEntity /** 子菜单 */ private List children = new ArrayList(); + /** 菜单区分标识*/ + private Long distinguish; + + public Long getDistinguish() { + return distinguish; + } + + public void setDistinguish(Long distinguish) { + this.distinguish = distinguish; + } + public Long getMenuId() { return menuId; diff --git a/ruoyi-system/src/main/resources/mapper/system/SysMenuMapper.xml b/ruoyi-system/src/main/resources/mapper/system/SysMenuMapper.xml index cdd15167..9f1d22b1 100644 --- a/ruoyi-system/src/main/resources/mapper/system/SysMenuMapper.xml +++ b/ruoyi-system/src/main/resources/mapper/system/SysMenuMapper.xml @@ -25,10 +25,12 @@ + + - select menu_id, menu_name, parent_id, order_num, path, component, `query`, is_frame, is_cache, menu_type, visible, status, ifnull(perms,'') as perms, icon, create_time + select distinguish, menu_id, menu_name, parent_id, order_num, path, component, `query`, is_frame, is_cache, menu_type, visible, status, ifnull(perms,'') as perms, icon, create_time from sys_menu @@ -41,6 +43,9 @@ AND visible = #{visible} + + AND distinguish=#{distinguish} + AND status = #{status} @@ -49,7 +54,7 @@ @@ -69,6 +74,9 @@ AND m.status = #{status} + + + AND m.distinguish = #{distinguish} order by m.parent_id, m.order_num @@ -143,6 +151,7 @@ icon = #{icon}, remark = #{remark}, update_by = #{updateBy}, + distinguish = #{distinguish}, update_time = sysdate() where menu_id = #{menuId} @@ -166,6 +175,7 @@ icon, remark, create_by, + distinguish, create_time )values( #{menuId}, @@ -184,6 +194,7 @@ #{icon}, #{remark}, #{createBy}, + #{distinguish}, sysdate() )