Commit d83f87da by 姜雷

修改登录后先进入首页后再导航到数据首页

parent 01f6779e
......@@ -84,6 +84,7 @@
import { mapActions } from 'vuex';
import { fetchVcode } from '@/api/user/login';
import CodeView from './components/CodeView';
import { setTimeout } from 'timers';
export default {
name: 'login',
......@@ -149,9 +150,13 @@ export default {
if (
userRoles.find(
item => item.menuCode === process.env.VUE_APP_DASHBOARD_CODE
)
) &&
process.env.VUE_APP_BASE_URL === '/'
) {
this.$router.push({ path: '/' });
setTimeout(() => {
this.$router.push({ name: 'dashboard' });
}, 400);
} else {
this.$router.push({ path: '/' });
}
......
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