mirror of
https://gitee.com/ccnetcore/Yi
synced 2026-03-12 20:49:28 +08:00
22 lines
620 B
TypeScript
22 lines
620 B
TypeScript
import { get, post } from '@/utils/request';
|
|
|
|
// 获取用户信息
|
|
export function getUserInfo() {
|
|
return get<any>('/account/ai').json();
|
|
}
|
|
|
|
// 获取二维码 LoginOrRegister 登录注册, Bind 绑定
|
|
export function getQrCode(data: any) {
|
|
return post<any>(`/fuwuhao/qrcode?sceneType=${data.sceneType}`, data).json();
|
|
}
|
|
|
|
// 扫码轮询
|
|
// 0=Wait, 1=Login, 2=Register, 3=Bind, 10=Expired
|
|
export function getQrCodeResult(data: any) {
|
|
return get<any>('/fuwuhao/qrcode/result', data).json();
|
|
}
|
|
// 注册微信授权
|
|
export function getWechatAuth(data: any) {
|
|
return post<any>('/fuwuhao/register', data).json();
|
|
}
|