ui: qemu disk: honor iothread setting from config

To have a IOThread on by default in the wizard and on disk add, we
added a 'bind' for the value here. This also changes the value for
existing VM disks, and if one does not notice, modifies it away again
(since we don't have the controller here and isSCSISingle is false)

Simply don't bind value when we edit a VM disk from config

Note that this is only an issue in Chromium based browsers.

Signed-off-by: Dominik Csapak <d.csapak@proxmox.com>
This commit is contained in:
Dominik Csapak 2022-11-21 15:39:06 +01:00 committed by Thomas Lamprecht
parent 783870bfc2
commit 00e4bd2e10

View File

@ -255,10 +255,12 @@ Ext.define('PVE.qemu.HDInputPanel', {
name: 'iothread',
fieldLabel: 'IO thread',
clearOnDisable: true,
bind: {
bind: me.insideWizard || me.isCreate ? {
disabled: '{!isVirtIO && !isSCSI}',
// Checkbox.setValue handles Arrays in a different way, therefore cast to bool
value: '{!!isVirtIO || (isSCSI && isSCSISingle)}',
} : {
disabled: '{!isVirtIO && !isSCSI}',
},
},
);