(code: string)
| 33 | }) |
| 34 | }, |
| 35 | async dingCallback(code: string) { |
| 36 | return LoginApi.getDingCallback(code).then((ok) => { |
| 37 | this.token = ok?.data?.token |
| 38 | localStorage.setItem('token', ok?.data?.token) |
| 39 | const user = useUserStore() |
| 40 | return user.profile() |
| 41 | }) |
| 42 | }, |
| 43 | async dingOauth2Callback(code: string) { |
| 44 | return LoginApi.getDingOauth2Callback(code).then((ok) => { |
| 45 | this.token = ok?.data?.token |