fix: 增加扫码

This commit is contained in:
Gsh
2025-08-29 22:01:44 +08:00
parent 1fbd521d1a
commit b70c530754
3 changed files with 262 additions and 73 deletions

View File

@@ -1,6 +1,21 @@
import { get } from '@/utils/request';
import { get, post } from '@/utils/request';
// 获取用户信息
export function getUserInfo() {
return get<any>('/ai-chat/account').json();
}
// 获取二维码 LoginOrRegister 登录注册, Bind 绑定
export function getQrCode(data: any) {
return post<any>('/fuwuhao/qrcode', 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();
}