diff options
Diffstat (limited to 'frontend/src/api/Maps.tsx')
| -rw-r--r-- | frontend/src/api/Maps.tsx | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/frontend/src/api/Maps.tsx b/frontend/src/api/Maps.tsx index 6bdc3e6..8295cf2 100644 --- a/frontend/src/api/Maps.tsx +++ b/frontend/src/api/Maps.tsx | |||
| @@ -97,4 +97,13 @@ export const post_record = async (token: string, run: UploadRunContent): Promise | |||
| 97 | }); | 97 | }); |
| 98 | return response.data.message; | 98 | return response.data.message; |
| 99 | } | 99 | } |
| 100 | } | ||
| 101 | |||
| 102 | export const delete_map_record = async (token: string, map_id: number, record_id: number): Promise<boolean> => { | ||
| 103 | const response = await axios.delete(url(`maps/${map_id}/record/${record_id}`), { | ||
| 104 | headers: { | ||
| 105 | "Authorization": token, | ||
| 106 | } | ||
| 107 | }); | ||
| 108 | return response.data.success; | ||
| 100 | }; | 109 | }; |