From 77baa2f30c0e9935d34c2ebef9116433f5f382a7 Mon Sep 17 00:00:00 2001 From: Arthur Lu Date: Mon, 30 Jan 2023 23:35:26 +0000 Subject: [PATCH] fix disk detach and disk resize issues Signed-off-by: Arthur Lu --- scripts/config.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/scripts/config.js b/scripts/config.js index 894c862..2ee147b 100644 --- a/scripts/config.js +++ b/scripts/config.js @@ -167,7 +167,7 @@ async function handleDiskDetach () { node: node, type: type, vmid: vmid, - action: `delete=${this.id}` + action: JSON.stringify({delete: this.id}) }; let result = await requestAPI("/disk/detach", "POST", body); if (result.status === 200) { @@ -199,7 +199,7 @@ async function handleDiskResize () { node: node, type: type, vmid: vmid, - action: `disk=${this.id}&size=+${form.get("size-increment")}G` + action: JSON.stringify({disk: this.id, size: `+${form.get("size-increment")}G`}) } let result = await requestAPI("/disk/resize", "POST", body); if (result.status === 200) {