Commit 02ae44f4 authored by wangxuelai's avatar wangxuelai

''

parent 7788907f
......@@ -17,6 +17,6 @@
</head>
<body>
<div id="root"></div>
<script src="dist/main.js?1574908459032" charset="utf-8"></script>
<script src="dist/main.js?1574915153188" charset="utf-8"></script>
</body>
</html>
\ No newline at end of file
......@@ -64,10 +64,16 @@ export default {
});
// 监听路由变化 判断缓存是否存在 实现路由守卫的功能
if (pathname.indexOf('hdqrs') == -1) {
const { menus } = JSON.parse(JSON.stringify(menuConfig));
if (LocalStorage.getItem('role') == 5) {
if (menus.find(ele => ele.id == 30)) {
menus.splice(menus.findIndex(ele => ele.id == 30), 1);
}
}
dispatch({
type: 'updateState',
payload: {
menus: menuConfig.menus,
menus,
isDepartment: false,
},
});
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment