字段修改+权限存入

This commit is contained in:
ym1026
2025-09-09 10:00:01 +08:00
parent 2f602ad72a
commit 79e99379a0
7 changed files with 22 additions and 26 deletions

View File

@@ -149,15 +149,15 @@ export default {
})
},
initRoute() {
console.log(localStorage.getItem('user'), "localStorage.getItem('user')")
console.log(localStorage.getItem('permission'), "localStorage.getItem('permission')")
// 执行过滤
const filteredRoutes = this.filterRoutes(
this.menuList,
JSON.parse(localStorage.getItem('user'))
)
// const filteredRoutes = this.filterRoutes(
// this.menuList,
// JSON.parse(localStorage.getItem('permission'))
// )
console.log( this.$route.matched, 'filteredRoutes')
this.subMenu = this.$route.matched[1].children || []
// this.menuList= JSON.parse(localStorage.getItem('user'))
// this.menuList= JSON.parse(localStorage.getItem('permission'))
// this.subMenu =filteredRoutes[0].children||[]
this.currentKey = '/' + this.$route.fullPath.split('/')[1]