feat(system/client): 新增客户端管理

This commit is contained in:
KAI
2024-12-26 02:19:09 +00:00
committed by Charles7c
parent 4ec42d1b79
commit bc3a5cff91
15 changed files with 605 additions and 17 deletions

View File

@@ -3,6 +3,7 @@ import { computed, reactive, ref } from 'vue'
import { resetRouter } from '@/router'
import {
type AccountLoginReq,
AuthTypeEnum,
type EmailLoginReq,
type PhoneLoginReq,
type UserInfo,
@@ -71,7 +72,7 @@ const storeSetup = () => {
// 三方账号登录
const socialLogin = async (source: string, req: any) => {
const res = await socialLoginApi(source, req)
const res = await socialLoginApi({ ...req, source, clientId: import.meta.env.VITE_CLIENT_ID, authType: AuthTypeEnum.SOCIAL_AUTH })
setToken(res.data.token)
token.value = res.data.token
}