Commit 9fda9f24 authored by Dietmar Maurer's avatar Dietmar Maurer

GUI: add new vtype ConfigId, use it for snapshot names

parent 0d4b9658
pve-manager (4.0-49) unstable; urgency=medium pve-manager (4.0-49) unstable; urgency=medium
* GUI: add new vtype ConfigId, use it for snapshot names
* IP4_cidr_match: allow short masks like /8 * IP4_cidr_match: allow short masks like /8
-- Proxmox Support Team <support@proxmox.com> Fri, 09 Oct 2015 08:16:55 +0200 -- Proxmox Support Team <support@proxmox.com> Fri, 09 Oct 2015 08:16:55 +0200
......
...@@ -73,7 +73,12 @@ Ext.apply(Ext.form.field.VTypes, { ...@@ -73,7 +73,12 @@ Ext.apply(Ext.form.field.VTypes, {
StorageId: function(v) { StorageId: function(v) {
return (/^[a-z][a-z0-9\-\_\.]*[a-z0-9]$/i).test(v); return (/^[a-z][a-z0-9\-\_\.]*[a-z0-9]$/i).test(v);
}, },
StorageIdText: gettext("Allowed characters") + ": 'a-z', '0-9', '-', '_', '.'", StorageIdText: gettext("Allowed characters") + ": 'A-Z', 'a-z', '0-9', '-', '_', '.'",
ConfigId: function(v) {
return (/^[a-z][a-z0-9\_]+$/i).test(v);
},
ConfigIdText: gettext("Allowed characters") + ": 'A-Z', 'a-z', '0-9', '_'",
HttpProxy: function(v) { HttpProxy: function(v) {
return (/^http:\/\/.*$/).test(v); return (/^http:\/\/.*$/).test(v);
......
...@@ -71,7 +71,7 @@ Ext.define('PVE.window.LxcSnapshot', { ...@@ -71,7 +71,7 @@ Ext.define('PVE.window.LxcSnapshot', {
name: 'snapname', name: 'snapname',
value: me.snapname, value: me.snapname,
fieldLabel: gettext('Name'), fieldLabel: gettext('Name'),
vtype: 'StorageId', vtype: 'ConfigId',
allowBlank: false allowBlank: false
} }
]; ];
......
...@@ -71,7 +71,7 @@ Ext.define('PVE.window.Snapshot', { ...@@ -71,7 +71,7 @@ Ext.define('PVE.window.Snapshot', {
name: 'snapname', name: 'snapname',
value: me.snapname, value: me.snapname,
fieldLabel: gettext('Name'), fieldLabel: gettext('Name'),
vtype: 'StorageId', vtype: 'ConfigId',
allowBlank: false allowBlank: false
} }
]; ];
......
...@@ -73,7 +73,12 @@ Ext.apply(Ext.form.field.VTypes, { ...@@ -73,7 +73,12 @@ Ext.apply(Ext.form.field.VTypes, {
StorageId: function(v) { StorageId: function(v) {
return (/^[a-z][a-z0-9\-\_\.]*[a-z0-9]$/i).test(v); return (/^[a-z][a-z0-9\-\_\.]*[a-z0-9]$/i).test(v);
}, },
StorageIdText: gettext("Allowed characters") + ": 'a-z', '0-9', '-', '_', '.'", StorageIdText: gettext("Allowed characters") + ": 'A-Z', 'a-z', '0-9', '-', '_', '.'",
ConfigId: function(v) {
return (/^[a-z][a-z0-9\_]+$/i).test(v);
},
ConfigIdText: gettext("Allowed characters") + ": 'A-Z', 'a-z', '0-9', '_'",
HttpProxy: function(v) { HttpProxy: function(v) {
return (/^http:\/\/.*$/).test(v); return (/^http:\/\/.*$/).test(v);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment