v3.8.2 开启TopNav没有子菜单情况隐藏侧边栏

This commit is contained in:
YunaiV
2022-03-20 22:58:13 +08:00
parent 82a3a8387c
commit 1a2c03bc7e
44 changed files with 76 additions and 71 deletions

View File

@@ -108,6 +108,7 @@ export default {
value: val
})
if (!val) {
this.$store.dispatch('app/toggleSideBarHide', false);
this.$store.commit("SET_SIDEBAR_ROUTERS", this.$store.state.permission.defaultRoutes);
}
}
@@ -162,7 +163,7 @@ export default {
this.sideTheme = val;
},
saveSetting() {
this.$modal.loading("正在保存到本地,请稍...");
this.$modal.loading("正在保存到本地,请稍...");
this.$cache.local.set(
"layout-setting",
`{
@@ -178,7 +179,7 @@ export default {
setTimeout(this.$modal.closeLoading(), 1000)
},
resetSetting() {
this.$modal.loading("正在清除设置缓存并刷新,请稍...");
this.$modal.loading("正在清除设置缓存并刷新,请稍...");
this.$cache.local.remove("layout-setting")
setTimeout("window.location.reload()", 1000)
}