but not in wizard, and default is off (because we do not know if the cpu supports it)
Signed-off-by: Dominik Csapak <d.csa...@proxmox.com> --- www/manager6/qemu/CreateWizard.js | 1 + www/manager6/qemu/ProcessorEdit.js | 20 ++++++++++++++++++++ 2 files changed, 21 insertions(+) diff --git a/www/manager6/qemu/CreateWizard.js b/www/manager6/qemu/CreateWizard.js index 30bf8878..dc8413a7 100644 --- a/www/manager6/qemu/CreateWizard.js +++ b/www/manager6/qemu/CreateWizard.js @@ -104,6 +104,7 @@ Ext.define('PVE.qemu.CreateWizard', { hdpanel, { xtype: 'pveQemuProcessorPanel', + insideWizard: true, title: gettext('CPU') }, { diff --git a/www/manager6/qemu/ProcessorEdit.js b/www/manager6/qemu/ProcessorEdit.js index 01da7036..2bb86a3a 100644 --- a/www/manager6/qemu/ProcessorEdit.js +++ b/www/manager6/qemu/ProcessorEdit.js @@ -3,12 +3,19 @@ Ext.define('PVE.qemu.ProcessorInputPanel', { alias: 'widget.pveQemuProcessorPanel', onlineHelp: 'qm_cpu', + insideWizard: false, + onGetValues: function(values) { var me = this; // build the cpu options: me.cpu.cputype = values.cputype; + + // as long as flags is not a textfield, we + // have to manuall set the value + me.cpu.flags = (values.flags)?'+pcid':undefined; delete values.cputype; + delete values.flags; var cpustring = PVE.Parser.printQemuCpu(me.cpu); // remove cputype delete request: @@ -95,6 +102,16 @@ Ext.define('PVE.qemu.ProcessorInputPanel', { fieldLabel: gettext('Total cores'), name: 'totalcores', value: '1' + }, + { + // will be a textfield probably someday, + // so we name it flags + hidden: me.insideWizard, + disabled: me.insideWizard, + xtype: 'pvecheckbox', + fieldLabel: 'PCID', + name: 'flags', + uncheckedValue: 0 } ]; @@ -126,6 +143,9 @@ Ext.define('PVE.qemu.ProcessorEdit', { var cpu = PVE.Parser.parseQemuCpu(value); ipanel.cpu = cpu; data.cputype = cpu.cputype; + /*jslint confusion: true*/ + // .flags is boolean and string + data.flags = (cpu.flags === '+pcid'); } me.setValues(data); } -- 2.11.0 _______________________________________________ pve-devel mailing list pve-devel@pve.proxmox.com https://pve.proxmox.com/cgi-bin/mailman/listinfo/pve-devel