if (store.state.user.userId == 1) {
next()
} else {
const workPtyId = store.getters.workPtyIds
if (to.path === '/doctor/business/doctorWork' && workPtyId.indexOf(10102408) == -1) {
backs()
} else if (to.path === '/outpatient/business/mzRegisterCharge' && workPtyId.indexOf(10102403) == -1) {
backs()
} else {
next()
}
}
function backs() {
store.dispatch("tagsView/delView", router)
Message.error('您没有权限访问该页面')
router.replace({ path: "/" })
}
08-01
770
![](https://csdnimg.cn/release/blogv2/dist/pc/img/readCountWhite.png)
08-13
2万+
![](https://csdnimg.cn/release/blogv2/dist/pc/img/readCountWhite.png)
“相关推荐”对你有帮助么?
-
非常没帮助
-
没帮助
-
一般
-
有帮助
-
非常有帮助
提交