Can upload ISO files

This commit is contained in:
2023-09-05 13:19:25 +02:00
parent 83ccd3a4b9
commit 036595fb24
24 changed files with 671 additions and 36 deletions

View File

@ -0,0 +1,21 @@
import { APIClient } from "./ApiClient";
export class IsoFilesApi {
/**
* Upload a new ISO file to the server
*/
static async Upload(
file: File,
progress: (progress: number) => void
): Promise<void> {
const fd = new FormData();
fd.append("file", file);
await APIClient.exec({
method: "POST",
uri: "/iso/upload",
formData: fd,
progress: progress,
});
}
}