[pve-devel] [PATCH manager 3/3] ui/storage: cifs: reoder fields

Thomas Lamprecht t.lamprecht at proxmox.com
Fri Jun 29 13:08:19 CEST 2018


user storage and domain name are all related, they are non-pve
options related to accessing the CIFS storage and have all influence
on the pveCIFSScan component.
So group those three together. Move the content type selector to the
right, as the RBD and other panels do.

Signed-off-by: Thomas Lamprecht <t.lamprecht at proxmox.com>
---
 www/manager6/storage/CIFSEdit.js | 46 ++++++++++++++++----------------
 1 file changed, 23 insertions(+), 23 deletions(-)

diff --git a/www/manager6/storage/CIFSEdit.js b/www/manager6/storage/CIFSEdit.js
index 2be08c7a..70a7ac3a 100644
--- a/www/manager6/storage/CIFSEdit.js
+++ b/www/manager6/storage/CIFSEdit.js
@@ -142,20 +142,29 @@ Ext.define('PVE.storage.CIFSInputPanel', {
 		    }
 		}
 	    },
+	    passwordfield,
+	    {
+		xtype: me.isCreate ? 'textfield' : 'displayfield',
+		name: 'domain',
+		value: me.isCreate ? '' : undefined,
+		fieldLabel: gettext('Domain'),
+		allowBlank: true,
+		listeners: {
+		    change: function(f, value) {
+			if (me.isCreate) {
+
+			    var exportField = me.down('field[name=share]');
+			    exportField.setDomain(value);
+			}
+		    }
+		}
+	    },
 	    {
 		xtype: me.isCreate ? 'pveCIFSScan' : 'displayfield',
 		name: 'share',
 		value: '',
 		fieldLabel: 'Share',
 		allowBlank: false
-	    },
-	    {
-		xtype: 'pveContentTypeSelector',
-		name: 'content',
-		value: 'images',
-		multiSelect: true,
-		fieldLabel: gettext('Content'),
-		allowBlank: false
 	    }
 	];
 
@@ -170,22 +179,13 @@ Ext.define('PVE.storage.CIFSInputPanel', {
 		value: me.isCreate ? '1' : undefined,
 		allowBlank: false
 	    },
-	    passwordfield,
 	    {
-		xtype: me.isCreate ? 'textfield' : 'displayfield',
-		name: 'domain',
-		value: me.isCreate ? '' : undefined,
-		fieldLabel: gettext('Domain'),
-		allowBlank: true,
-		listeners: {
-		    change: function(f, value) {
-			if (me.isCreate) {
-
-			    var exportField = me.down('field[name=share]');
-			    exportField.setDomain(value);
-			}
-		    }
-		}
+		xtype: 'pveContentTypeSelector',
+		name: 'content',
+		value: 'images',
+		multiSelect: true,
+		fieldLabel: gettext('Content'),
+		allowBlank: false
 	    }
 	];
 
-- 
2.17.1




More information about the pve-devel mailing list