first commit

This commit is contained in:
编码猿
2024-09-27 02:06:13 +08:00
commit 852d94fbb9
36760 changed files with 3274413 additions and 0 deletions

View File

@@ -0,0 +1,37 @@
权限控制 页面权限,按钮权限
动态路由
思路:
1:后台在登录的时候,后端一般会给token,权限数组
管理后台的导航菜单,一般两级菜单
[
{
"title": "用户管理"
"icon": "user",
"zujian": "",
"path": "/user",
"children": [
{
"title": "删除用户"
"icon": "delete",
"zujian": "",
"path": "/delete",
"children":
},
{
"title": "增加用户"
"icon": "add",
"zujian": "",
"path": "/add",
"children":
}
]
}
]
2: 使用权限数组生成左侧的导航菜单
3:使用权限数组生成路由的配置文件,然后动态的追加到vue-router中,addRouters 让动态路由生效