修改路由

This commit is contained in:
Jason 2022-09-16 17:13:56 +08:00
parent 3ce89c21cf
commit 50aeb20502
1 changed files with 1 additions and 1 deletions

View File

@ -86,7 +86,7 @@ export function findFirstValidRoute(routes: RouteRecordRaw[]): string | undefine
}
//通过权限字符查询路由路径
export function getRoutePath(perms: string) {
console.log(router.getRoutes())
const router = useRouter()
return router.getRoutes().find((item) => item.meta?.perms == perms)?.path || ''
}