Browse Source

fix 修复 前端参数漏改导致三方跳转失败问题

疯狂的狮子Li 1 năm trước cách đây
mục cha
commit
13bb23c717
1 tập tin đã thay đổi với 3 bổ sung2 xóa
  1. 3 2
      src/api/login.ts

+ 3 - 2
src/api/login.ts

@@ -67,10 +67,11 @@ export function getCodeImg(): AxiosPromise<VerifyCodeResult> {
 export function socialLogin(source: string, code: any, state: any): AxiosPromise<any> {
   const data = {
     code,
-    state
+    state,
+    source
   };
   return request({
-    url: '/auth/social-login/' + source,
+    url: '/auth/social-login',
     method: 'get',
     params: data
   });