This commit is contained in:
trochas
2026-01-09 15:24:30 +01:00
5 changed files with 21 additions and 24 deletions

View File

@@ -80,7 +80,8 @@ export const coachService = {
// controller doesn't declare a class-level path consistently; support both common patterns
create: (data: any) => api.post<CoachDTO>(`/coach/create`, data),
getAll: () => api.get(`/coach/all`),
getByKeycloakId: (id: number | string) => api.get(`/coach/${id}`),
getById: (id: number) => api.get(`/coach/${id}`),
getByKeycloakId: (keycloakId: string) => api.get(`/coach/keycloak/${keycloakId}`),
update: (id: number | string, data: any) => api.put(`/coach/update/${id}`, data),
delete: (id: number | string) => api.delete(`/coach/delete/${id}`),
getSessionsForCoach: (coachId: number | string) => api.get(`/coach/${coachId}/session`),