* 使用一次性 code 交换 OIDC 登录结果 * @param {string} code - 一次性登录 code * @returns {Promise<{ * access_token: string, * token_type: string, * user_id: number, * username: string, * uid: string, * phone_number: string | null, * avatar: string | null, * role: string, * department_id
()
| 60 | * }>} |
| 61 | */ |
| 62 | async function getUserAccessOptions() { |
| 63 | return apiAdminGet('/api/auth/users/access-options') |
| 64 | } |
| 65 | |
| 66 | async function exchangeOIDCCode(code) { |
| 67 | const response = await fetch('/api/auth/oidc/exchange-code', { |
nothing calls this directly
no test coverage detected