fix storageSelect and sizeInput populating

Signed-off-by: Arthur Lu <learthurgo@gmail.com>
This commit is contained in:
Arthur Lu 2023-01-16 15:16:02 -08:00
parent 0aa983594f
commit 36d93017f9

View File

@ -137,14 +137,16 @@ function addDiskLine (fieldset, busPrefix, busName, device, storage, storageOpti
} }
}); });
storageSelect.value = storage; storageSelect.value = storage;
field.append(storageSelect);
let sizeInput = document.createElement("input"); let sizeInput = document.createElement("input");
sizeInput.type = "number"; sizeInput.type = "number";
sizeInput.min = 0; sizeInput.min = 0;
deviceInput.value = size; sizeInput.value = size;
if (!diskConfig[type][busPrefix].resizable) { if (!diskConfig[type][busPrefix].resizable) {
deviceInput.disabled = true; sizeInput.disabled = true;
} }
field.append(sizeInput);
} }
function getOrderedUsed(entry){ function getOrderedUsed(entry){