diff --git a/src/layout/components/SocialCallback/index.vue b/src/layout/components/SocialCallback/index.vue index 5e3d704..ef02c2d 100644 --- a/src/layout/components/SocialCallback/index.vue +++ b/src/layout/components/SocialCallback/index.vue @@ -27,6 +27,9 @@ const processResponse = async (res: any) => { if (res.code !== 200) { throw new Error(res.msg); } + if (res.data !== null) { + setToken(res.data.access_token); + } ElMessage.success(res.msg); location.href = import.meta.env.VITE_APP_CONTEXT_PATH + 'index'; };