diff --git a/server/model/sys_base_menu.go b/server/model/sys_base_menu.go index f9ec18b1..c9dbe510 100644 --- a/server/model/sys_base_menu.go +++ b/server/model/sys_base_menu.go @@ -24,6 +24,7 @@ type Meta struct { DefaultMenu bool `json:"defaultMenu" gorm:"comment:是否是基础路由(开发中)"` Title string `json:"title" gorm:"comment:菜单名"` Icon string `json:"icon" gorm:"comment:菜单图标"` + CloseTab bool `json:"closeTab" gorm:"comment:自动关闭tab"` } type SysBaseMenuParameter struct { diff --git a/web/src/store/module/router.js b/web/src/store/module/router.js index 8272e025..b284e0ad 100644 --- a/web/src/store/module/router.js +++ b/web/src/store/module/router.js @@ -8,7 +8,6 @@ const formatRouter = (routes) => { if ((!item.children || item.children.every(ch => ch.hidden)) && item.name != '404') { routerList.push({ label: item.meta.title, value: item.name }) } - item.meta.hidden = item.hidden if (item.children && item.children.length > 0) { formatRouter(item.children) } diff --git a/web/src/view/layout/aside/historyComponent/history.vue b/web/src/view/layout/aside/historyComponent/history.vue index 4c94906b..f717301b 100644 --- a/web/src/view/layout/aside/historyComponent/history.vue +++ b/web/src/view/layout/aside/historyComponent/history.vue @@ -9,9 +9,9 @@ v-model="activeValue" > @@ -27,73 +27,75 @@ \ No newline at end of file diff --git a/web/src/view/layout/index.vue b/web/src/view/layout/index.vue index 6749b46e..046119d1 100644 --- a/web/src/view/layout/index.vue +++ b/web/src/view/layout/index.vue @@ -36,7 +36,7 @@
- + @@ -67,11 +67,11 @@ - + - + @@ -98,7 +98,7 @@ export default { isMobile: false, isShadowBg: false, loadingFlag:false, - + reloadFlag:true, value: '' } }, @@ -112,6 +112,12 @@ export default { }, methods: { ...mapActions('user', ['LoginOut']), + reload(){ + this.reloadFlag = false + this.$nextTick(()=>{ + this.reloadFlag = true + }) + }, totalCollapse() { this.isCollapse = !this.isCollapse this.isSider = !this.isCollapse @@ -153,6 +159,7 @@ export default { } this.$bus.emit('collapse', this.isCollapse) this.$bus.emit('mobile', this.isMobile) + this.$bus.on("reload",this.reload) this.$bus.on("showLoading",()=>{ this.loadingFlag = true }) diff --git a/web/src/view/layout/search/search.vue b/web/src/view/layout/search/search.vue index abc7dfa4..b0352139 100644 --- a/web/src/view/layout/search/search.vue +++ b/web/src/view/layout/search/search.vue @@ -19,8 +19,14 @@
+
+ +
- +
@@ -48,9 +54,9 @@ export default { }, showSearch() { this.show = true; - this.$nextTick(()=>{ - this.$refs['search-input'].focus() - }) + this.$nextTick(() => { + this.$refs["search-input"].focus(); + }); } } }; diff --git a/web/src/view/superAdmin/menu/menu.vue b/web/src/view/superAdmin/menu/menu.vue index 8db813a3..b4dd84b8 100644 --- a/web/src/view/superAdmin/menu/menu.vue +++ b/web/src/view/superAdmin/menu/menu.vue @@ -117,6 +117,12 @@ + + + + + +
新增菜单需要在角色管理内配置权限才可使用
@@ -209,6 +215,7 @@ export default { title: "", icon: "", defaultMenu: false, + closeTab: false, keepAlive: false }, parameters: []