ui: lxc/MPEdit: add updateVMConfig

helper for the upcoming MultiMPEdit

Signed-off-by: Dominik Csapak <d.csapak@proxmox.com>
Tested-by: Lorenz Stechauner <l.stechauner@proxmox.com>
Tested-by: Aaron Lauterer <a.lauterer@proxmox.com>
This commit is contained in:
Dominik Csapak 2021-10-05 13:28:57 +02:00 committed by Thomas Lamprecht
parent cef0b24cff
commit 09e7ac8b63

View File

@ -75,12 +75,18 @@ Ext.define('PVE.lxc.MountPointInputPanel', {
}
},
setVMConfig: function(vmconfig) {
updateVMConfig: function(vmconfig) {
let me = this;
let vm = me.getViewModel();
me.vmconfig = vmconfig;
vm.set('unpriv', vmconfig.unprivileged);
me.down('field[name=mpid]').validate();
},
setVMConfig: function(vmconfig) {
let me = this;
me.updateVMConfig(vmconfig);
PVE.Utils.forEachMP((bus, i) => {
let name = "mp" + i.toString();
if (!Ext.isDefined(vmconfig[name])) {