父路由重定向问题
#12307
Replies: 1 comment
-
你在要跳 url 之前,得去找一下这个用户第一个有权限的路由是哪个,然后再去跳有权限的路由,可能要写一个通用的跳转方法。 如果想跳之后解决,最好把 access 方案改成运行时的(不配在静态路由表配置里,或者用一个其他字段,然后用 或者还有一个更晚的时机,就是自定义下 layout 的无权限 |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
父路由重定向到子一个固定的子路由,登录不同账号这个子路由会没有权限,怎么让父路由动态重定向的地址是第一个有权限的子路由
{
path: '/student',
name: '学生',
icon: 'SearchOutlined',
routes: [
{
redirect: 'analysis',
path: '/student',
},
{
name: '课程分析',
path: 'analysis',
component: './student/analysis/index',
access: 'routerAuthor',
},
]
}
Beta Was this translation helpful? Give feedback.
All reactions