Commit 07253302 authored by 前端-许佳敏's avatar 前端-许佳敏

fix: 修复路由

parent a2c239b2
......@@ -64,12 +64,15 @@ export function patchRoutes({ routes }: IRoutes) {
if (isDev) {
return;
}
PublicApi.getMemberLoginReget({}, { useCache: true, ttl: 1000 }).then(res => {
const { data, code } = res
if (code === 1000) {
asyncRouter(data.urls, routes)
}
})
const authInfo = getAuth()
if (authInfo) {
PublicApi.getMemberLoginReget({}, { useCache: true, ttl: 1000 }).then(res => {
const { data, code } = res
if (code === 1000) {
asyncRouter(data.urls, routes)
}
})
}
}
/**
......
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