Refactor: Rename NanoKVM to BatchuKVM and update server URL

This commit is contained in:
2025-12-09 20:35:38 +09:00
commit 8cf674c9e5
396 changed files with 54380 additions and 0 deletions

32
web/src/api/storage.ts Normal file
View File

@@ -0,0 +1,32 @@
import { http } from '@/lib/http.ts';
// get image list
export function getImages() {
return http.get('/api/storage/image');
}
// get mounted image
export function getMountedImage() {
return http.get('/api/storage/image/mounted');
}
// mount/unmount image
export function mountImage(file?: string, cdrom?: boolean) {
const data = {
file: file ? file : '',
cdrom: cdrom
};
return http.post('/api/storage/image/mount', data);
}
// get CD-ROM flag
export function getCdRom() {
return http.get('/api/storage/cdrom');
}
export function deleteImage(file: string) {
const data = {
file
};
return http.post('/api/storage/image/delete', data);
}