[pve-devel] [PATCH manager] ui: resource mappings: fix editing of mapping for non first node
Dominik Csapak
d.csapak at proxmox.com
Fri Apr 26 09:17:24 CEST 2024
when editing the pci mapping, we set the nodename of the pciselector
to the selected node. At the same time we disable and hide the node
selector, but it still changes it's value to the 'first' node
(alphabetically sorted) and that triggers a change event.
To prevent that we accidentally set the node of the pciselector
too, we need to check here if the field is disabled.
Signed-off-by: Dominik Csapak <d.csapak at proxmox.com>
---
www/manager6/window/PCIMapEdit.js | 6 ++++--
1 file changed, 4 insertions(+), 2 deletions(-)
diff --git a/www/manager6/window/PCIMapEdit.js b/www/manager6/window/PCIMapEdit.js
index d43f04eb..faf58255 100644
--- a/www/manager6/window/PCIMapEdit.js
+++ b/www/manager6/window/PCIMapEdit.js
@@ -126,8 +126,10 @@ Ext.define('PVE.window.PCIMapEditWindow', {
this.lookup('pciselector').setMdev(value);
},
- nodeChange: function(_field, value) {
- this.lookup('pciselector').setNodename(value);
+ nodeChange: function(field, value) {
+ if (!field.isDisabled()) {
+ this.lookup('pciselector').setNodename(value);
+ }
},
pciChange: function(_field, value) {
--
2.39.2
More information about the pve-devel
mailing list