[pve-devel] [PATCH manager 3/5] move valueField and displayField to class config

Dominik Csapak d.csapak at proxmox.com
Fri Apr 1 13:10:59 CEST 2016


if we do not do this, we cannot select items
(used in the clone window for example)

Signed-off-by: Dominik Csapak <d.csapak at proxmox.com>
---
 www/manager6/form/PoolSelector.js     | 4 ++--
 www/manager6/form/SnapshotSelector.js | 5 +++--
 2 files changed, 5 insertions(+), 4 deletions(-)

diff --git a/www/manager6/form/PoolSelector.js b/www/manager6/form/PoolSelector.js
index 912b43c..376468a 100644
--- a/www/manager6/form/PoolSelector.js
+++ b/www/manager6/form/PoolSelector.js
@@ -3,6 +3,8 @@ Ext.define('PVE.form.PoolSelector', {
     alias: ['widget.pvePoolSelector'],
 
     allowBlank: false,
+    valueField: 'poolid',
+    displayField: 'poolid',
 
     initComponent: function() {
 	var me = this;
@@ -14,8 +16,6 @@ Ext.define('PVE.form.PoolSelector', {
 	Ext.apply(me, {
 	    store: store,
 	    autoSelect: false,
-	    valueField: 'poolid',
-	    displayField: 'poolid',
             listConfig: {
 		columns: [
 		    {
diff --git a/www/manager6/form/SnapshotSelector.js b/www/manager6/form/SnapshotSelector.js
index 074e405..ea7d460 100644
--- a/www/manager6/form/SnapshotSelector.js
+++ b/www/manager6/form/SnapshotSelector.js
@@ -2,6 +2,9 @@ Ext.define('PVE.form.SnapshotSelector', {
     extend: 'PVE.form.ComboGrid',
     alias: ['widget.PVE.form.SnapshotSelector'],
 
+    valueField: 'name',
+    displayField: 'name',
+
     loadStore: function(nodename, vmid) {
 	var me = this;
 
@@ -43,8 +46,6 @@ Ext.define('PVE.form.SnapshotSelector', {
 
 	Ext.apply(me, {
 	    store: store,
-	    valueField: 'name',
-	    displayField: 'name',
             listConfig: {
 		columns: [
 		    {
-- 
2.1.4





More information about the pve-devel mailing list