Add loading UserList for admin user
This commit is contained in:
parent
ba054ef2b9
commit
ac3450239e
4 changed files with 22 additions and 10 deletions
|
|
@ -3,13 +3,14 @@ import type {UserDto} from "../dtos/UserDto";
|
|||
import type {CreateUserRequest} from "../dtos/CreateUserRequest.ts";
|
||||
import type {ChangeUserPasswordRequest} from "../dtos/ChangeUserPasswordRequest.ts";
|
||||
import type {CreateUserResponse} from "../dtos/CreateUserResponse.ts";
|
||||
import type {UserListResponse} from "../dtos/UserListResponse.ts";
|
||||
|
||||
export async function fetchCurrentUser(): Promise<UserDto> {
|
||||
return apiClient.get("/user/me");
|
||||
}
|
||||
|
||||
export async function fetchAllUsers(): Promise<UserDto[]> {
|
||||
return apiClient.get("/user/list");
|
||||
export async function fetchAllUsers(): Promise<UserListResponse> {
|
||||
return apiClient.get("/user/all");
|
||||
}
|
||||
|
||||
export async function createUser(dto: CreateUserRequest): Promise<CreateUserResponse> {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue