Commit ed4cf5ec authored by tyn's avatar tyn

fix

parent 0aaa8737
...@@ -64,6 +64,7 @@ const routes = [ ...@@ -64,6 +64,7 @@ const routes = [
const router = new VueRouter({ const router = new VueRouter({
mode: 'history', mode: 'history',
base: process.env.BASE_URL, base: process.env.BASE_URL,
routes
}); });
export default router; export default router;
......
...@@ -39,9 +39,7 @@ router.beforeEach((to, from, next) => { ...@@ -39,9 +39,7 @@ router.beforeEach((to, from, next) => {
if (to.meta?.needToken === false) { if (to.meta?.needToken === false) {
next(); next();
} else { } else {
next({ next();
path: "/login"
});
} }
} }
}); });
\ No newline at end of file
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