Step UX-1:通用选择器
This commit is contained in:
@@ -1,5 +1,5 @@
|
||||
import { apiGet } from "./axios";
|
||||
import type { ApiListResponse } from "../types/api";
|
||||
|
||||
export const fetchSites = (studyId: string) =>
|
||||
apiGet<ApiListResponse<any>>(`/api/v1/studies/${studyId}/sites/`);
|
||||
export const fetchSites = (studyId: string, params?: Record<string, any>) =>
|
||||
apiGet<ApiListResponse<any>>(`/api/v1/studies/${studyId}/sites/`, { params });
|
||||
|
||||
@@ -0,0 +1,5 @@
|
||||
import { apiGet } from "./axios";
|
||||
import type { ApiListResponse } from "../types/api";
|
||||
|
||||
export const fetchUsers = (params?: Record<string, any>) =>
|
||||
apiGet<ApiListResponse<any>>("/api/v1/users", { params });
|
||||
Reference in New Issue
Block a user