diff --git a/public/logo.jpg b/public/logo.jpg index b54bdf7..bf032a1 100644 Binary files a/public/logo.jpg and b/public/logo.jpg differ diff --git a/src/router/index.ts b/src/router/index.ts index 7caed2b..625cbd2 100644 --- a/src/router/index.ts +++ b/src/router/index.ts @@ -1,5 +1,7 @@ import { createRouter, createWebHistory, RouteRecordRaw } from "vue-router"; import Login from "@/views/login/index.vue"; //登录组件 +import Layout from "@/views/layout/index.vue"; //首页布局 +import CallBack from "@/views/login/OauthCallBack.vue"; //反馈页面 const routes: Array = [ { @@ -7,6 +9,16 @@ const routes: Array = [ name: "Login", component: Login, }, + { + path: "/callback", + name: "CallBack", + component: CallBack, + }, + { + path: "/layout", + name: "Layout", + component: Layout, + }, ]; const router = createRouter({ diff --git a/src/views/layout/index.vue b/src/views/layout/index.vue index e69de29..fc64ac4 100644 --- a/src/views/layout/index.vue +++ b/src/views/layout/index.vue @@ -0,0 +1,8 @@ + + + + \ No newline at end of file diff --git a/src/views/login/OauthCallBack.vue b/src/views/login/OauthCallBack.vue index 66e2d54..20a0edd 100644 --- a/src/views/login/OauthCallBack.vue +++ b/src/views/login/OauthCallBack.vue @@ -13,11 +13,10 @@ const router = useRouter(); const message = useMessage(); const oSomethingWithToken = async () => { try { + console.log('进来了吗??'); token.value = await getAccessTokenSilently(); - setTimeout(() => { - message.success('登录成功!'); - router.push('/layout'); - }, 5000); + message.success('登录成功!'); + router.push('/layout'); } catch (error) { router.push('/'); message.error('错误!');