[pve-devel] [PATCH manager v2 4/5] gui: add tag edit windows for guests

Dominik Csapak d.csapak at proxmox.com
Thu Oct 3 13:50:13 CEST 2019


so that the user can edit the tags in the gui

Signed-off-by: Dominik Csapak <d.csapak at proxmox.com>
---
 www/manager6/lxc/Options.js  | 13 +++++++++++++
 www/manager6/qemu/Options.js | 13 +++++++++++++
 2 files changed, 26 insertions(+)

diff --git a/www/manager6/lxc/Options.js b/www/manager6/lxc/Options.js
index 23409938..049b35e3 100644
--- a/www/manager6/lxc/Options.js
+++ b/www/manager6/lxc/Options.js
@@ -141,6 +141,19 @@ Ext.define('PVE.lxc.Options', {
 		editor: Proxmox.UserName === 'root at pam' ?
 		    'PVE.lxc.FeaturesEdit' : undefined
 	    },
+	    tags: {
+		header: gettext('Tags'),
+		defaultValue: false,
+		renderer: val => val || Proxmox.Utils.noneText,
+		editor: caps.vms['VM.Config.Options'] ? {
+		    xtype: 'proxmoxWindowEdit',
+		    subject: gettext('Tags'),
+		    items: {
+			xtype: 'pveTagSelector',
+			name: 'tags',
+		    }
+		} : undefined
+	    },
 	    hookscript: {
 		header: gettext('Hookscript')
 	    }
diff --git a/www/manager6/qemu/Options.js b/www/manager6/qemu/Options.js
index e1580060..e17d8576 100644
--- a/www/manager6/qemu/Options.js
+++ b/www/manager6/qemu/Options.js
@@ -281,6 +281,19 @@ Ext.define('PVE.qemu.Options', {
 		    }
 		} : undefined
 	    },
+	    tags: {
+		header: gettext('Tags'),
+		defaultValue: false,
+		renderer: val => val || Proxmox.Utils.noneText,
+		editor: caps.vms['VM.Config.Options'] ? {
+		    xtype: 'proxmoxWindowEdit',
+		    subject: gettext('Tags'),
+		    items: {
+			xtype: 'pveTagSelector',
+			name: 'tags',
+		    }
+		} : undefined
+	    },
 	    hookscript: {
 		header: gettext('Hookscript')
 	    }
-- 
2.20.1





More information about the pve-devel mailing list