Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[已实现]后端动态路由模板 #1369

Open
wants to merge 166 commits into
base: template
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
166 commits
Select commit Hold shift + click to select a range
8919e94
package.json更新
simon9124 Apr 26, 2020
21e6e03
eslint规则更新
simon9124 Apr 26, 2020
1635ced
标签title更新
simon9124 Apr 26, 2020
c6fbaef
eslint规则更新
simon9124 Apr 26, 2020
bb1e8e9
eslint规则更新
simon9124 Apr 26, 2020
c280122
追加删除token事件
simon9124 Apr 26, 2020
aae9db1
用户登出时删除token
simon9124 Apr 26, 2020
ee1a3f3
临时
simon9124 Apr 26, 2020
6c988b8
Merge branch 'master' of https://github.com/simon9124/iview-dynamicRo…
simon9124 Apr 26, 2020
35b7ccf
update readme
simon9124 Apr 26, 2020
0c1e09f
Update README.md
simon9124 Apr 26, 2020
95cd241
Update README.md
simon9124 Apr 26, 2020
23d0e7a
axios加工改造,使其更符合后端的回文格式
simon9124 Apr 27, 2020
ecac0f0
mock登录加工改造
simon9124 Apr 27, 2020
c27b287
store > user加工改造
simon9124 Apr 27, 2020
fc9601d
登录事件改造,获取token才拉取用户信息
simon9124 Apr 27, 2020
7b2e8d8
git部署修改BASE_URL
simon9124 Apr 27, 2020
a8156f0
github部署修改baseUrl
simon9124 Apr 27, 2020
4040bc7
github部署baseUrl更新
simon9124 Apr 27, 2020
1125ec4
github部署时修改baseUrl
simon9124 Apr 27, 2020
79cab7e
github部署时,生产环境同样引入mock
simon9124 Apr 27, 2020
bf9bcec
部署到github gh-pages -> 取消路由history模式
simon9124 Apr 27, 2020
95b5308
Update README.md
simon9124 Apr 27, 2020
3c8813f
Update README.md
simon9124 Apr 27, 2020
ee07677
Update README.md
simon9124 Apr 27, 2020
315c3f3
Update README.md
simon9124 Apr 27, 2020
5bdccf3
注册mock事件:getAllMenus
simon9124 Apr 27, 2020
aec7c1b
Update README.md
simon9124 Apr 27, 2020
657ae08
函数: 引入组件
simon9124 Apr 27, 2020
f709b96
Merge branch 'master' of https://github.com/simon9124/iview-dynamicRo…
simon9124 Apr 27, 2020
e24103a
用户列表更新
simon9124 Apr 27, 2020
eaf472f
路由数据处理通用function封装
simon9124 Apr 27, 2020
2e0ceb4
临时
simon9124 Apr 27, 2020
1889fc1
vuex:用户退出时,清空路由和标签缓存
simon9124 Apr 28, 2020
9afa079
模板页面
simon9124 Apr 28, 2020
dcfeef1
Update README.md
simon9124 Apr 28, 2020
57f3b3a
Update README.md
simon9124 Apr 28, 2020
1d445c3
Update README.md
simon9124 Apr 28, 2020
1e90620
左侧菜单获取方式更新
simon9124 Apr 28, 2020
fca549d
原始路由表
simon9124 Apr 28, 2020
23e2d62
登录页面路由初始化,清空动态添加的路由
simon9124 Apr 28, 2020
8789be7
动态路由
simon9124 Apr 28, 2020
e0b25bf
Update README.md
simon9124 Apr 30, 2020
1b51425
追加通用方法封装
simon9124 May 6, 2020
24d958a
mockData:用户数据更新
simon9124 May 6, 2020
54e8beb
封装方法更新
simon9124 May 6, 2020
cdafa1f
大屏界面
simon9124 May 6, 2020
18800a4
mockData:角色更新
simon9124 May 6, 2020
55562f9
追加:①二级大屏路由的数据处理;②前端控制路由权限
simon9124 May 6, 2020
b5da188
Update README.md
simon9124 May 6, 2020
8dcf3bc
Update README.md
simon9124 May 6, 2020
fa2dbbb
Update README.md
simon9124 May 6, 2020
58571b0
Update README.md
simon9124 May 6, 2020
b8c33d5
Update README.md
simon9124 May 6, 2020
0438912
Update README.md
simon9124 May 6, 2020
2adf825
Update README.md
simon9124 May 6, 2020
19dc14a
Update README.md
simon9124 May 6, 2020
ea2d612
修改语言类型
simon9124 May 7, 2020
cbfc3a4
修改项目语言类型
simon9124 May 7, 2020
cd3a4cc
Update README.md
simon9124 May 7, 2020
9d1b3c8
Update README.md
simon9124 May 7, 2020
f32a7a8
Update README.md
simon9124 May 7, 2020
8bc8090
Update README.md
simon9124 May 13, 2020
51cfea7
路由封装方法更新
simon9124 May 14, 2020
0d1d817
菜单模拟数据更新
simon9124 May 14, 2020
715372c
路由数据更新
simon9124 May 14, 2020
067ba63
Update README.md
simon9124 May 15, 2020
3f067b7
Update README.md
simon9124 May 15, 2020
641ae0d
Update README.md
simon9124 May 15, 2020
3931485
Update README.md
simon9124 May 15, 2020
6d47f2d
Update README.md
simon9124 May 18, 2020
ed895eb
Update README.md
simon9124 May 18, 2020
4ded2d0
Update README.md
simon9124 May 18, 2020
03b5819
Update README.md
simon9124 May 18, 2020
d52bc72
node-sass安装
simon9124 May 18, 2020
100f3d9
validate方法封装
simon9124 May 18, 2020
753b82f
vuex - 修改user配置
simon9124 May 18, 2020
5970693
mock事件更新:用户登录 & 拉取用户信息
simon9124 May 18, 2020
fb45691
mock数据更新:追加用户列表
simon9124 May 18, 2020
51fede3
菜单栏样式修改
simon9124 May 18, 2020
a901d46
权限管理
simon9124 May 18, 2020
893a354
根据routers设置首页
simon9124 May 18, 2020
c7e5bb6
追加配置主页方法
simon9124 May 18, 2020
400366d
追加mock方法
simon9124 May 18, 2020
fc167f2
追加hideInBread处理
simon9124 May 18, 2020
2d7495d
追加hideInBread处理
simon9124 May 18, 2020
ae07292
mockData:用户列表更新
simon9124 May 18, 2020
765de9d
权限管理:用户管理
simon9124 May 18, 2020
7affc7c
Update README.md
simon9124 May 18, 2020
8632e88
追加默认头像
simon9124 May 19, 2020
420cdff
mock事件更新:login & getUserInfo
simon9124 May 19, 2020
6a70a7a
用户管理
simon9124 May 19, 2020
ed44751
dynamicRouter -> dynamicRouter-template
simon9124 May 19, 2020
01c4174
登录提示优化
simon9124 May 25, 2020
f70d2fb
Update README.md
simon9124 May 25, 2020
c202092
iview版本更新
simon9124 May 25, 2020
9dff0ec
代码优化
simon9124 May 25, 2020
4c3ce62
角色管理
simon9124 May 25, 2020
8da2336
mockData:用户更新
simon9124 May 25, 2020
07a9107
api更新
simon9124 May 25, 2020
f51cf25
通用方法封装更新
simon9124 May 25, 2020
ace3cf0
组件:icon选择器
simon9124 May 26, 2020
65171f2
图标选择组件更新
simon9124 May 26, 2020
e6a645e
通用方法更新:菜单转化数组时,去掉一些冗余字段
simon9124 May 26, 2020
a93e2d6
table追加标识;追加新增方法
simon9124 May 27, 2020
7284d03
追加方法:遍历routes路由数据,手动往router.options.routes里添加数据
simon9124 May 27, 2020
b788718
菜单管理
simon9124 May 27, 2020
4a7fb83
追加封装好的方法的使用
simon9124 May 27, 2020
b7821c7
菜单列表追加description字段
simon9124 May 27, 2020
a92eed8
方法名称更新
simon9124 May 28, 2020
0c80849
方法名称更新
simon9124 May 28, 2020
fbd6850
追加通用函数: 遍历routes路由数据 * 1.手动往router.options.routes里添加数据 * 2.如routes里…
simon9124 May 28, 2020
7ec9247
bug处理:1.更新系统名页面401问题;2.更新系统名或url有时提示重复问题
simon9124 May 28, 2020
a8cd951
左侧菜单sort排序更新
simon9124 May 29, 2020
c34800b
新增菜单后,清空表单
simon9124 May 29, 2020
810f12b
模块菜单隐藏”层级“选项
simon9124 May 29, 2020
51545d0
菜单数据处理方法更新
simon9124 May 29, 2020
2f0ec35
刷新页面时菜单数据获取方式更新
simon9124 May 29, 2020
cf4ada8
函数:遍历后台传来的路由数据,转为路由基础数据
simon9124 May 29, 2020
d2d7a60
路由基础数据方法:排序和重定向的递归
simon9124 May 29, 2020
77c73da
localStorage:tagNaveList -> tagNaveList-template
simon9124 Jun 1, 2020
7111f26
动态获取路由:一些浏览器console优化
simon9124 Jun 1, 2020
e551259
新增菜单时,如果是外链 -> path值不能为空否则影响父级路由的重定向 ->设置为任意常量
simon9124 Jun 1, 2020
9d7ad10
原始数据外链的path设置不为空
simon9124 Jun 1, 2020
a4c0f13
通用方法优化
simon9124 Jun 1, 2020
46844e7
处理父子菜单的标签位置
simon9124 Jun 1, 2020
9a172f8
处理父子菜单的标签位置
simon9124 Jun 1, 2020
fe5bca0
routerDataHanding通用方法更新:处理重定向
simon9124 Jun 1, 2020
007303e
routerDataHanding通用方法更新:处理重定向
simon9124 Jun 1, 2020
34c5be0
mockData:隐藏用户头像
simon9124 Jun 8, 2020
47533de
菜单管理:自适应优化
simon9124 Jun 8, 2020
1062991
用户登录更新
simon9124 Jun 10, 2020
47a9b58
菜单列表的注释更新
simon9124 Jun 10, 2020
09d770f
优化一些注释
simon9124 Jun 15, 2020
b3ece49
优化一些注释
simon9124 Jun 15, 2020
39d7e75
删除removeToken方法
simon9124 Jun 15, 2020
02c3a79
一些注释的更新
simon9124 Jun 17, 2020
1a0d7cc
一些注释的更新
simon9124 Jun 17, 2020
8da6660
静态路由变量名更新
simon9124 Jun 17, 2020
bb286b0
更新左侧动态菜单的渲染方式
simon9124 Jun 19, 2020
81ffd75
静态菜单数据修正
simon9124 Jun 19, 2020
ed98c2f
1.修改menuList渲染方式;2.更新一些注释
simon9124 Jun 19, 2020
587fd27
更新一些注释
simon9124 Jun 19, 2020
6a2dc87
Update README.md
simon9124 Jun 22, 2020
1e5ad4e
Update README.md
simon9124 Jun 22, 2020
d6bcfbb
Update README.md
simon9124 Jun 22, 2020
86b96a7
Update README.md
simon9124 Jun 22, 2020
d2c1c92
Update README.md
simon9124 Jun 22, 2020
857ffa3
Update README.md
simon9124 Jun 22, 2020
4d8b446
Update README.md
simon9124 Jun 22, 2020
3b719e8
Update README.md
simon9124 Jun 22, 2020
d803c5f
Update README.md
simon9124 Jun 22, 2020
4a915fd
Update README.md
simon9124 Jun 23, 2020
ecf7dd0
Update README.md
simon9124 Jun 23, 2020
8529d17
Update README.md
simon9124 Jun 24, 2020
0545a49
模拟数据更新:角色列表
simon9124 Jun 24, 2020
c13c978
角色管理:更新角色-菜单关联时,对左侧菜单栏刷新
simon9124 Jun 24, 2020
cdb95e1
Update README.md
simon9124 Jun 28, 2020
1dd5f6b
Update README.md
simon9124 Jun 28, 2020
f48965c
Update README.md
simon9124 Jun 28, 2020
7d4f7de
Update README.md
simon9124 Jun 28, 2020
16ac3e1
Update README.md
simon9124 Jun 28, 2020
5e67d4c
Update README.md
simon9124 Jun 28, 2020
4cdfef1
Update README.md
simon9124 Jun 28, 2020
5ba93a8
全局注册事件中心
simon9124 Jun 29, 2020
634e317
更新菜单时,tag标签在事件总线做相应更新
simon9124 Jun 29, 2020
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
30 changes: 20 additions & 10 deletions .eslintrc.js
Original file line number Diff line number Diff line change
@@ -1,18 +1,28 @@
module.exports = {
root: true,
'extends': [
'plugin:vue/essential',
'@vue/standard'
],
extends: ["plugin:vue/essential", "@vue/standard"],
rules: {
// allow async-await
'generator-star-spacing': 'off',
"generator-star-spacing": "off",
// allow debugger during development
'no-debugger': process.env.NODE_ENV === 'production' ? 'error' : 'off',
'vue/no-parsing-error': [2, { 'x-invalid-end-tag': false }],
'no-undef': 'off'
"no-debugger": process.env.NODE_ENV === "production" ? "error" : "off",
"vue/no-parsing-error": [
2,
{
"x-invalid-end-tag": false
}
],
"no-undef": "off",
camelcase: "off",
quotes: [1, "double"],
semi: ["error", "always"],
"space-before-function-paren": [0, "always"]
// "space-before-function-paren": [2, {
// "anonymous": "never",
// "named": "never"
// }]
},
parserOptions: {
parser: 'babel-eslint'
parser: "babel-eslint"
}
}
};
3 changes: 3 additions & 0 deletions .gitattributes
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
*.js linguist-language=Vue
*.css linguist-language=Vue
*.html linguist-language=Vue
330 changes: 143 additions & 187 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,187 +1,143 @@
<p align="center">
<a href="https://www.iviewui.com">
<img width="200" src="https://file.iviewui.com/logo-new.svg">
</a>
</p>

# iView Admin

[![](https://img.shields.io/github/release/iview/iview-admin.svg)](https://github.com/iview/iview-admin/releases)
[![](https://img.shields.io/travis/iview/iview-admin.svg?style=flat-square)](https://travis-ci.org/iview/iview-admin)
[![vue](https://img.shields.io/badge/vue-2.5.10-brightgreen.svg?style=flat-square)](https://github.com/vuejs/vue)
[![iview ui](https://img.shields.io/badge/iview-3.0.0-brightgreen.svg?style=flat-square)](https://github.com/iview/iview)
[![npm](https://img.shields.io/npm/l/express.svg)]()

[更新日志](https://github.com/iview/iview-admin/releases)

[使用文档](https://lison16.github.io/iview-admin-doc/#/)

[在线访问](https://admin.iviewui.com/)

[简化版模板](https://github.com/iview/iview-admin/tree/template)

[教学视频(26课时)](https://segmentfault.com/ls/1650000016221751?utm_source=banner)

`注:在线版本会在开发版本新小版本发布后更新到相应版本,所以如果想体验最新版本iview-admin,请clone完整项目代码到本地运行。`

## Install
```bush
// install dependencies
npm install
```
## Run
### Development
```bush
npm run dev
```
### Production(Build)
```bush
npm run build
```

## 简介
&emsp;&emsp;iView admin是基于Vue.js,搭配使用[iView](https://www.iviewui.com) UI组件库形成的一套后台集成解决方案,由TalkingData前端可视化团队部分成员开发维护。iView admin遵守iView设计和开发约定,风格统一,设计考究,并且更多功能在不停开发中。
如果您想查看iview-admin的更新动态,您可以到[更新日志](https://github.com/iview/iview-admin/releases)查看了解最新更新;如果您是新手,想快速入手iview-admin,您可以到[使用教程](https://github.com/iview/iview-admin/wiki)查看讲解;如果您想在线体验iview-admin,您可以到[在线访问](https://admin.iviewui.com/)体验。如果你只是想要一个清醒爽朗的界面,那你可以下载[简化版模板](https://github.com/iview/iview-admin/tree/template)来做开发。

## 功能

- 登录/登出
- 权限管理
- 列表过滤
- 权限切换
- 多语言切换
- 组件
- 富文本编辑器
- Markdown编辑器
- 城市级联
- 图片预览编辑
- 可拖拽列表
- 文件上传
- 数字渐变
- split-pane
- 表单编辑
- 文章发布
- 工作流
- 表格
- 可拖拽排序
- 可编辑表格
- 行内编辑
- 单元格编辑
- 可搜索表格
- 表格导出数据
- 导出为Csv文件
- 导出为Xls文件
- 表格转图片
- 错误页面
- 403页面
- 404页面
- 500页面
- 高级路由
- 动态路由
- 带参页面
- 换肤
- 收缩侧边栏
- tag标签导航
- 面包屑导航
- 全屏/退出全屏
- 锁屏
- 消息中心
- 个人中心

## 文件结构
```shell
.
├── build 项目构建配置
├── config 开发相关配置
├── public 打包所需静态资源
└── src
├── api AJAX请求
└── assets 项目静态资源
├── icons 自定义图标资源
└── images 图片资源
├── components 业务组件
├── config 项目运行配置
├── directive 自定义指令
├── libs 封装工具函数
├── locale 多语言文件
├── mock mock模拟数据
├── router 路由配置
├── store Vuex配置
├── view 页面文件
└── tests 测试相关
```

## Links

- [TalkingData](https://github.com/TalkingData)
- [iView](https://github.com/iview/iview)
- [Vue](https://github.com/vuejs/vue)
- [Webpack](https://github.com/webpack/webpack)

## 效果展示

- 响应式布局首页
![image](https://github.com/iview/iview-admin/raw/dev/github-gif/home.gif)

- 标签导航
![image](https://github.com/iview/iview-admin/raw/dev/github-gif/page-tags.gif)

- 权限管理
![image](https://github.com/iview/iview-admin/raw/dev/github-gif/access.gif)

- 可拖拽列表
![image](https://github.com/iview/iview-admin/raw/dev/github-gif/dragable-list.gif)

- 图片预览编辑
![image](https://github.com/iview/iview-admin/raw/dev/github-gif/image-editor.gif)

- 文件上传
![image](https://github.com/iview/iview-admin/raw/dev/github-gif/upload.gif)

- 数字渐变
![image](https://github.com/iview/iview-admin/raw/dev/github-gif/count-to.gif)

- split-pane
![image](https://github.com/iview/iview-admin/raw/dev/github-gif/split-pane.gif)

- 文章发布
![image](https://github.com/iview/iview-admin/raw/dev/github-gif/article-publish.gif)

- 工作流
![image](https://github.com/iview/iview-admin/raw/dev/github-gif/workflow.gif)

- 可拖拽表格
![image](https://github.com/iview/iview-admin/raw/dev/github-gif/dragable-table.gif)

- 可编辑表格
![image](https://github.com/iview/iview-admin/raw/dev/github-gif/editable-table.gif)

- 表格导出数据
![image](https://github.com/iview/iview-admin/raw/dev/github-gif/exportable-table.gif)

- 表格转图片
![image](https://github.com/iview/iview-admin/raw/dev/github-gif/table2image.gif)

- 错误页面
![image](https://github.com/iview/iview-admin/raw/dev/github-gif/error-page.gif)

- 锁屏
![image](https://github.com/iview/iview-admin/raw/dev/github-gif/locking.gif)

- 可收缩侧边栏
![image](https://github.com/iview/iview-admin/raw/dev/github-gif/sidebarmenu.gif)

- 主题切换
![image](https://github.com/iview/iview-admin/raw/dev/github-gif/theme.gif)

- 消息中心
![image](https://github.com/iview/iview-admin/raw/dev/github-gif/message.gif)

### 💖💖 If you find this project helpful, maybe you can buy me a coffee. 💖💖
![image](https://github.com/iview/iview-admin/raw/dev/github-gif/code.png)


## License
[MIT](http://opensource.org/licenses/MIT)

Copyright (c) 2016-present, iView
<p align="center">
<a href="https://www.iviewui.com">
<img width="200" src="https://file.iviewui.com/logo-new.svg">
</a>
</p>

# iView DynamicRouter

<a href="https://github.com/vuejs/vue">
<img src="https://img.shields.io/badge/vue-2.5.10-brightgreen.svg?style=flat-square">
</a>
<a href="https://github.com/iview/iview">
<img src="https://img.shields.io/badge/iview-3.1.3-brightgreen.svg?style=flat-square">
</a>
<a href="https://github.com/iview/iview-admin/tree/template">
<img src="https://img.shields.io/badge/iview--admin-template-brightgreen">
</a>
<p></p>

<a href="https://github.com/simon9124/iview-dynamicRouter" target="_blank">iView-DynamicRouter</a> 基于 <a href="https://github.com/iview/iview-admin/tree/template" target="_blank">iview-admin(branch:template)</a>,由“后端动态提供路由数据,经前端处理后生成动态路由和菜单”的【后端动态路由模板】,内置“权限管理”业务模型,可任意调整左侧菜单栏、修改其相关权限、监听当前路由和菜单,是一套更安全、更智能的后台管理系统模板。

## 在线预览

- <a href="https://simon9124.github.io/iview-dynamicRouter" target="_blank">iview-dynamicRouter →</a>
- userName:goku / trunks
- password:any / any

> 在控制台可监听 **当前路由和菜单**

## 使用文档

如果你想快速使用,请看 <a href="https://simon9124.github.io/iview-dynamicRouter-doc" target="_blank">**配置文档 →**</a>
如果你想和我一起,从 **iview-admin** 的原始框架一步步实现 **iView-DynamicRouter**,请看 <a href="https://simon9124.github.io/iview-dynamicRouter-doc/develop/axios/" target="_blank">**开发指南 →**</a>

## 功能特点

登录后,**不同权限**的用户监听到不同的**动态路由**和**动态菜单**:

<img src="https://user-gold-cdn.xitu.io/2020/6/28/172f9ddb32aa32e3?w=1910&h=922&f=gif&s=1838123">

菜单自由**选择上级**、自由**增删改**:

<img src="https://user-gold-cdn.xitu.io/2020/6/28/172f9840378af7c0?w=1361&h=791&f=gif&s=1252459">

自由**选择菜单的层级**,大屏路由亦可在子菜单挂载:

<img src="https://user-gold-cdn.xitu.io/2020/6/28/172f9847696b997c?w=1505&h=851&f=gif&s=942974">

修改“角色-菜单”关联,**控制菜单权限**:

<img src="https://user-gold-cdn.xitu.io/2020/6/28/172f9dee14301a7d?w=1505&h=860&f=gif&s=1438180">

功能汇总:

```bash
- 动态路由数据
- 路由改造(静态路由+动态路由)
- 路由数据处理
- 手动添加路由
- 路由清空
- 路由监听

- 动态菜单渲染
- 菜单数据处理(大屏路由在二级/多级菜单)
- 菜单监听

- 动态模拟数据mockData
- 用户列表、角色列表、路由列表、路由层级

- 权限管理
- 用户管理(增删改查、用户1对多绑定角色)
- 角色管理(增删改查、角色1对多绑定菜单)
- 菜单管理(增删改查、修改层级、修改上级目录)
- 纯前端也可控制路由权限
```

## 目录结构

```bash
- config 开发相关配置
- public 打包所需静态资源
- src
- api AJAX请求 -> 追加:动态获取路由方法
- assets 项目静态资源
- icons 自定义图标资源
- images 图片资源
- components 业务组件
- config 项目运行配置
- directive 自定义指令
- libs 封装工具函数 -> 追加:若干路由数据处理函数
- locale 多语言文件
- mock mock模拟数据 -> 追加:路由列表、路由层级、角色列表 等数据
- router 路由配置 -> 有较多改动,路由改造
- store Vuex配置 -> 有较多改动,菜单渲染改造
- view 页面文件 -> 追加【权限管理】模块、追加 template.vue 和 screent.vue 页面模板
- tests 测试相关
```

## 安装使用

```bash
# 克隆项目
git clone https://github.com/simon9124/iview-dynamicRouter

# 进入项目目录
cd vue-element-admin

# 安装依赖
npm install

# 本地开发 启动项目
npm run dev
```

如果这个模板或模板中的代码段能够在开发中帮助到你,请到在 <a href="https://github.com/simon9124/iview-dynamicRouter" target="_blank">**项目地址**</a> 的右上角 :star: 一下,更可以买一杯果汁表示鼓励 :tropical_drink:,非常感谢!

<img width="300" src="https://mmbiz.qpic.cn/mmbiz_png/Tlm6c1DNgXRhxyU1EIlwed2ErNQvYG7FnsRE7yMOwSwBicVNVhzJsiaDuEaiahTeiavk3Tm1ic5z5etIe5PVvI0J70w/0?wx_fmt=png">

## 权限控制

启动完成后,在控制台可监听【当前路由】和【左侧菜单】:

<img src="https://mmbiz.qpic.cn/mmbiz_png/Tlm6c1DNgXQDvea6ZkJD5aNx25dymLfInAQzp6snhVQ36aH70AiaqINqCzFI60DiaIX0rkMjiaE7v8gIvY5TzxTnQ/0?wx_fmt=png">

权限管理 - 菜单管理,可任意新增/更新菜单、修改层级、修改上级目录:

<img src="https://mmbiz.qpic.cn/mmbiz_png/Tlm6c1DNgXRhxyU1EIlwed2ErNQvYG7FayPN5e59qlaRaL3bWk5wTHY4lIjk12IfZh9LHX5GUst1zictcTD5Ggg/0?wx_fmt=png">

权限管理 - 角色管理,可任意新增/更新角色、修改角色关联的菜单:

<img src="https://mmbiz.qpic.cn/mmbiz_png/Tlm6c1DNgXRhxyU1EIlwed2ErNQvYG7FxIxHjX8N9UeibatuJNPMQuFhhibEic9a3e4BXn1icQcoj7zVibEvgDvGgsw/0?wx_fmt=png">

权限管理 - 用户管理,可任意新增/更新用户、修改用户关联的角色:

<img src="https://mmbiz.qpic.cn/mmbiz_png/Tlm6c1DNgXRhxyU1EIlwed2ErNQvYG7FGmqiabpQSoJxjDbU1kQS70qXt7Bj7gjrZkaAuAP7OLjk28NyOTtD4Ig/0?wx_fmt=png">

实现路由权限控制:

<img src="https://mmbiz.qpic.cn/mmbiz_png/Tlm6c1DNgXSzsMiaymWHcjibfquK5EYaSzwLxvJvojntLcRLx8A8QUPIpQfa1lsSnLYykqHIF1jJ6jRJEasXJiaqA/0?wx_fmt=png">

大屏路由在二级/多级菜单亦可挂载:

<img src="https://mmbiz.qpic.cn/mmbiz_png/Tlm6c1DNgXSzsMiaymWHcjibfquK5EYaSz6zhTS8gF4n1gJOFRAqoQxm3IFCyUvPTicaVtWaicAaclqXDIn7TTw45A/0?wx_fmt=png">
Loading