[pve-devel] [PATCH manager 1/2] ui: clone: validate name

Fiona Ebner f.ebner at proxmox.com
Mon Apr 17 09:09:13 CEST 2023


As reported in the community forum[0], as opposed to VM/LXC creation,
there is no validation for the name in the clone dialog. Use the same
validation as the guest creation wizards do to catch errors early,
before sending the API request.

[0]: https://forum.proxmox.com/threads/125883/#post-549304

Signed-off-by: Fiona Ebner <f.ebner at proxmox.com>
---
 www/manager6/window/Clone.js | 1 +
 1 file changed, 1 insertion(+)

diff --git a/www/manager6/window/Clone.js b/www/manager6/window/Clone.js
index e94cd92d..e4ea17ad 100644
--- a/www/manager6/window/Clone.js
+++ b/www/manager6/window/Clone.js
@@ -191,6 +191,7 @@ Ext.define('PVE.window.Clone', {
 	{
 	    xtype: 'textfield',
 	    name: 'name',
+	    vtype: 'DnsName',
 	    allowBlank: true,
 	    fieldLabel: me.guestType === 'lxc' ? gettext('Hostname') : gettext('Name'),
 	},
-- 
2.30.2






More information about the pve-devel mailing list