mirror of
https://gitee.com/dromara/RuoYi-Cloud-Plus.git
synced 2026-04-27 10:59:37 +08:00
Merge branch 'master' of https://gitee.com/y_project/RuoYi-Cloud
Conflicts: README.md pom.xml ruoyi-api/pom.xml ruoyi-api/ruoyi-api-resource/pom.xml ruoyi-api/ruoyi-api-system/pom.xml ruoyi-auth/pom.xml ruoyi-common/pom.xml ruoyi-common/ruoyi-common-core/pom.xml ruoyi-common/ruoyi-common-core/src/main/java/com/ruoyi/common/core/utils/PageUtils.java ruoyi-common/ruoyi-common-core/src/main/java/com/ruoyi/common/core/utils/ip/IpUtils.java ruoyi-common/ruoyi-common-core/src/main/java/com/ruoyi/common/core/utils/poi/ExcelUtil.java ruoyi-common/ruoyi-common-core/src/main/java/com/ruoyi/common/core/web/controller/BaseController.java ruoyi-common/ruoyi-common-log/pom.xml ruoyi-common/ruoyi-common-mybatis/pom.xml ruoyi-common/ruoyi-common-redis/pom.xml ruoyi-common/ruoyi-common-security/pom.xml ruoyi-common/ruoyi-common-swagger/pom.xml ruoyi-gateway/pom.xml ruoyi-modules/pom.xml ruoyi-modules/ruoyi-gen/pom.xml ruoyi-modules/ruoyi-gen/src/main/resources/vm/vue/index-tree.vue.vm ruoyi-modules/ruoyi-job/pom.xml ruoyi-modules/ruoyi-resource/pom.xml ruoyi-modules/ruoyi-system/pom.xml ruoyi-modules/ruoyi-system/src/main/resources/mapper/system/SysUserMapper.xml ruoyi-ui/package.json ruoyi-ui/src/views/index.vue ruoyi-visual/pom.xml ruoyi-visual/ruoyi-monitor/pom.xml
This commit is contained in:
@@ -30,13 +30,14 @@
|
||||
<script>
|
||||
import { constantRoutes } from "@/router";
|
||||
|
||||
// 隐藏侧边栏路由
|
||||
const hideList = ['/index', '/user/profile'];
|
||||
|
||||
export default {
|
||||
data() {
|
||||
return {
|
||||
// 顶部栏初始数
|
||||
visibleNumber: 5,
|
||||
// 是否为首次加载
|
||||
isFrist: false,
|
||||
// 当前激活菜单的 index
|
||||
currentIndex: undefined
|
||||
};
|
||||
@@ -88,17 +89,10 @@ export default {
|
||||
activeMenu() {
|
||||
const path = this.$route.path;
|
||||
let activePath = path;
|
||||
if (path.lastIndexOf("/") > 0) {
|
||||
if (path !== undefined && path.lastIndexOf("/") > 0 && hideList.indexOf(path) === -1) {
|
||||
const tmpPath = path.substring(1, path.length);
|
||||
activePath = "/" + tmpPath.substring(0, tmpPath.indexOf("/"));
|
||||
this.$store.dispatch('app/toggleSideBarHide', false);
|
||||
} else if ("/index" == path || "" == path) {
|
||||
if (!this.isFrist) {
|
||||
this.isFrist = true;
|
||||
} else {
|
||||
activePath = "index";
|
||||
}
|
||||
this.$store.dispatch('app/toggleSideBarHide', true);
|
||||
} else if(!this.$route.children) {
|
||||
activePath = path;
|
||||
this.$store.dispatch('app/toggleSideBarHide', true);
|
||||
|
||||
Reference in New Issue
Block a user