On 09/28/2017 02:43 PM, Dominik Csapak wrote:
On 09/26/2017 01:56 PM, Thomas Lamprecht wrote:
It seemed a bit weird that those options were in a seprate edit
window as they affect the same backend variable and may cause
confusion, an user may not be sure in what way they are related to
each other, if at all.

This allows us to share the help button, the docs must be updated so
that the moved fields are represented there.

Further we reduce the count of non common buttons from the Hardware
View.

Signed-off-by: Thomas Lamprecht <t.lampre...@proxmox.com>
---

[snip]

diff --git a/www/manager6/qemu/ProcessorEdit.js 
b/www/manager6/qemu/ProcessorEdit.js
index 627d0c93..80c79236 100644
--- a/www/manager6/qemu/ProcessorEdit.js
+++ b/www/manager6/qemu/ProcessorEdit.js
@@ -2,10 +2,18 @@ Ext.define('PVE.qemu.ProcessorInputPanel', {
      extend: 'PVE.panel.InputPanel',
      alias: 'widget.pveQemuProcessorPanel',
      onlineHelp: 'qm_cpu',
+    insideWizard: false,
      controller: {
      xclass: 'Ext.app.ViewController',
      control: {
+        '#': {
+        beforerender: function(view) {
+            Ext.Array.each(this.wizardOnlyFields, function (field_ref) {
+            view.lookup(field_ref).setHidden(view.insideWizard);
+            });
+        }
+        },

for this, i would like we rather use the 'init' method of the viewcontroller,
this will be called after the views initcomponent and only once during the 
creation
beforerender will possibly called each time before it has to be rendered
not a very big issue though


Good suggestion, thanks! I'll send a v2 later, maybe I also find another thing
to improve.


_______________________________________________
pve-devel mailing list
pve-devel@pve.proxmox.com
https://pve.proxmox.com/cgi-bin/mailman/listinfo/pve-devel

Reply via email to