Update web/api.js
Browse files- web/api.js +3 -1
web/api.js
CHANGED
|
@@ -74,6 +74,8 @@ const api = (() => {
|
|
| 74 |
getConsultations: (page = 1, perPage = 10, search = '', filter = 'all') =>
|
| 75 |
get(`/api/consultations?page=${page}&per_page=${perPage}&search=${encodeURIComponent(search)}&filter=${filter}`),
|
| 76 |
|
|
|
|
|
|
|
| 77 |
saveConsultation: (data) => post('/api/consultations', data),
|
| 78 |
|
| 79 |
/* ── DASHBOARD ──────────────────────────────────────── */
|
|
@@ -88,4 +90,4 @@ const api = (() => {
|
|
| 88 |
};
|
| 89 |
})();
|
| 90 |
|
| 91 |
-
if (typeof window !== 'undefined') window.api = api;
|
|
|
|
| 74 |
getConsultations: (page = 1, perPage = 10, search = '', filter = 'all') =>
|
| 75 |
get(`/api/consultations?page=${page}&per_page=${perPage}&search=${encodeURIComponent(search)}&filter=${filter}`),
|
| 76 |
|
| 77 |
+
getConsultation: (id) => get(`/api/consultations/${id}`),
|
| 78 |
+
|
| 79 |
saveConsultation: (data) => post('/api/consultations', data),
|
| 80 |
|
| 81 |
/* ── DASHBOARD ──────────────────────────────────────── */
|
|
|
|
| 90 |
};
|
| 91 |
})();
|
| 92 |
|
| 93 |
+
if (typeof window !== 'undefined') window.api = api;
|