Commit 905fb787 authored by 陈珠河's avatar 陈珠河

Style: 调整进入路由时获取系统配置数据

parent 5b4d5a02
......@@ -64,15 +64,6 @@ router.beforeEach((to, from, next) => {
}
if (filterRouteLogin(to)) {
next();
return;
}
if (store.state.platformInfo &&
store.state.platformInfo.systemId &&
to.query.sysCode === from.query.sysCode) {
checkLogin(next);
} else {
const sysCode = to.query.sysCode;
getSystemInfo(sysCode).then(_ => {
checkLogin(next);
......@@ -86,15 +77,20 @@ router.beforeEach((to, from, next) => {
}
});
} else {
router.replace({
name: 'Login',
query: {
sysCode
next();
}
});
next();
return;
}
});
if (store.state.platformInfo &&
store.state.platformInfo.systemId &&
to.query.sysCode === from.query.sysCode) {
checkLogin(next);
return;
}
next();
});
router.afterEach(() => {
......
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