diff --git a/ruoyi-admin/src/main/resources/templates/index.html b/ruoyi-admin/src/main/resources/templates/index.html index fb2280a9..30cbfaeb 100644 --- a/ruoyi-admin/src/main/resources/templates/index.html +++ b/ruoyi-admin/src/main/resources/templates/index.html @@ -258,8 +258,6 @@ var skin = storage.get("skin"); var mode = "history"; // 历史访问路径缓存 var historyPath = storage.get("historyPath"); -// 排除非左侧菜单链接 -var excludesUrl = ["/system/user/profile"]; // 本地主题优先,未设置取系统配置 if($.common.isNotEmpty(skin)){ @@ -289,9 +287,7 @@ function switchSkin() { /** 刷新时访问路径页签 */ function applyPath(url) { $('a[href$="' + decodeURI(url) + '"]').click(); - if($.inArray(url, excludesUrl)){ - $('a[href$="' + url + '"]').parent("li").addClass("selected").parents("li").addClass("active").end().parents("ul").addClass("in"); - } + $('a[href$="' + url + '"]').parent("li").addClass("selected").parents("li :not(.user-panel)").addClass("active").end().parents("ul").addClass("in"); } $(function() {