From 64eb1c2ebfc25f11f5757a0eef04de230fa8fa15 Mon Sep 17 00:00:00 2001
From: zhengyiming <540361168@qq.com>
Date: 星期四, 04 十二月 2025 17:52:54 +0800
Subject: [PATCH] fix: 账号密码双因子登录

---
 src/services/api/Account.ts |   67 ++++++++++++++++++++++++++++++---
 1 files changed, 60 insertions(+), 7 deletions(-)

diff --git a/src/services/api/Account.ts b/src/services/api/Account.ts
index 3dc39aa..67f2e96 100644
--- a/src/services/api/Account.ts
+++ b/src/services/api/Account.ts
@@ -219,9 +219,17 @@
   });
 }
 
+/** 鏌ヨ绯荤粺淇℃伅 GET /api/Account/GetSystemInfo */
+export async function getSystemInfo(options?: API.RequestConfig) {
+  return request<API.GetSystemInfoOutput>('/api/Account/GetSystemInfo', {
+    method: 'GET',
+    ...(options || {}),
+  });
+}
+
 /** 鐢靛瓙绛剧櫥褰� POST /api/Account/GetTokenForUserSign */
 export async function getTokenForUserSign(body: API.AccessRequestDto, options?: API.RequestConfig) {
-  return request<API.IdentityModelTokenCacheItem>('/api/Account/GetTokenForUserSign', {
+  return request<API.IdentityModelToken>('/api/Account/GetTokenForUserSign', {
     method: 'POST',
     headers: {
       'Content-Type': 'application/json',
@@ -233,7 +241,7 @@
 
 /** 姝ゅ鍚庣娌℃湁鎻愪緵娉ㄩ噴 POST /api/Account/GetTokenForWeb */
 export async function getTokenForWeb(body: API.AccessRequestDto, options?: API.RequestConfig) {
-  return request<API.IdentityModelTokenCacheItem>('/api/Account/GetTokenForWeb', {
+  return request<API.IdentityModelToken>('/api/Account/GetTokenForWeb', {
     method: 'POST',
     headers: {
       'Content-Type': 'application/json',
@@ -313,7 +321,7 @@
 
 /** 瀵嗙爜鐧诲綍 POST /api/Account/PasswordLogin */
 export async function passwordLogin(body: API.PasswordLoginInput, options?: API.RequestConfig) {
-  return request<API.IdentityModelTokenCacheItem>('/api/Account/PasswordLogin', {
+  return request<API.IdentityModelToken>('/api/Account/PasswordLogin', {
     method: 'POST',
     headers: {
       'Content-Type': 'application/json',
@@ -328,7 +336,7 @@
   body: API.PhoneMesssageCodeLoginInput,
   options?: API.RequestConfig
 ) {
-  return request<API.IdentityModelTokenCacheItem>('/api/Account/PhoneMesssageCodeLogin', {
+  return request<API.IdentityModelToken>('/api/Account/PhoneMesssageCodeLogin', {
     method: 'POST',
     headers: {
       'Content-Type': 'application/json',
@@ -395,6 +403,51 @@
   });
 }
 
+/** 鍙屽洜瀛愮櫥褰�-绗竴姝ヨ处鍙峰瘑鐮佺櫥褰� POST /api/Account/TwoFactorLoginPassword */
+export async function twoFactorLoginPassword(
+  body: API.TwoFactorLoginPasswordInput,
+  options?: API.RequestConfig
+) {
+  return request<API.TwoFactorLoginPasswordOutput>('/api/Account/TwoFactorLoginPassword', {
+    method: 'POST',
+    headers: {
+      'Content-Type': 'application/json',
+    },
+    data: body,
+    ...(options || {}),
+  });
+}
+
+/** 鍙屽洜瀛愮浜屾-鍙戦�侀獙璇佺爜 POST /api/Account/TwoFactorLoginSendVerificationCode */
+export async function twoFactorLoginSendVerificationCode(
+  body: API.TwoFactorLoginSendVerificationCodeInput,
+  options?: API.RequestConfig
+) {
+  return request<number>('/api/Account/TwoFactorLoginSendVerificationCode', {
+    method: 'POST',
+    headers: {
+      'Content-Type': 'application/json',
+    },
+    data: body,
+    ...(options || {}),
+  });
+}
+
+/** 鍙屽洜瀛愮涓夋-楠岃瘉鐮佺櫥褰� POST /api/Account/TwoFactorLoginSms */
+export async function twoFactorLoginSms(
+  body: API.TwoFactorLoginSmsInput,
+  options?: API.RequestConfig
+) {
+  return request<API.IdentityModelToken>('/api/Account/TwoFactorLoginSms', {
+    method: 'POST',
+    headers: {
+      'Content-Type': 'application/json',
+    },
+    data: body,
+    ...(options || {}),
+  });
+}
+
 /** 瑙g粦鐢ㄦ埛閭 POST /api/Account/UnbindingUserEmail */
 export async function unbindingUserEmail(
   body: API.UnbindingUserEmailInput,
@@ -445,7 +498,7 @@
   body: API.WxMiniAppPhoneLoginInput,
   options?: API.RequestConfig
 ) {
-  return request<API.IdentityModelTokenCacheItem>('/api/Account/WxMiniAppPhoneAuthLogin', {
+  return request<API.IdentityModelToken>('/api/Account/WxMiniAppPhoneAuthLogin', {
     method: 'POST',
     headers: {
       'Content-Type': 'application/json',
@@ -460,7 +513,7 @@
   body: API.WxMiniAppPhoneAuthLoginFromScanInput,
   options?: API.RequestConfig
 ) {
-  return request<API.IdentityModelTokenCacheItem>('/api/Account/WxMiniAppPhoneAuthLoginFromScan', {
+  return request<API.IdentityModelToken>('/api/Account/WxMiniAppPhoneAuthLoginFromScan', {
     method: 'POST',
     headers: {
       'Content-Type': 'application/json',
@@ -490,7 +543,7 @@
   body: API.WxMiniAppUserLoginFromScanInput,
   options?: API.RequestConfig
 ) {
-  return request<API.IdentityModelTokenCacheItem>('/api/Account/WxMiniAppUserLoginFromScan', {
+  return request<API.IdentityModelToken>('/api/Account/WxMiniAppUserLoginFromScan', {
     method: 'POST',
     headers: {
       'Content-Type': 'application/json',

--
Gitblit v1.9.1