mirror of
https://git.victorphan.net/basketballcantho/ten-project.git
synced 2026-08-05 14:33:10 +07:00
Hoàn thành bước 3.3. Interactive Workbook (The Core Viewer)
This commit is contained in:
@@ -36,4 +36,13 @@ export const api = {
|
||||
uploadPdfs: (formData: FormData) =>
|
||||
request<import("@/types").PDFUploadResult[]>("/api/pdfs/upload", { method: "POST", body: formData }),
|
||||
deletePdf: (id: number) => request<void>(`/api/pdfs/${id}`, { method: "DELETE" }),
|
||||
|
||||
// Annotations
|
||||
getAnnotation: (pdfId: number, page: number) =>
|
||||
request<import("@/types").AnnotationData>(`/api/annotations/${pdfId}/${page}`),
|
||||
upsertAnnotation: (pdfId: number, page: number, body: { canvas_data: object }) =>
|
||||
request<import("@/types").AnnotationData>(`/api/annotations/${pdfId}/${page}`, {
|
||||
method: "PUT",
|
||||
body: JSON.stringify(body),
|
||||
}),
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user