[pve-devel] [PATCH manager v3 1/2] Add regexp to match a bus entry in a VM config
Emmanuel Kasper
e.kasper at proxmox.com
Thu Oct 6 11:01:25 CEST 2016
---
www/manager6/Utils.js | 2 ++
www/manager6/qemu/BootOrderEdit.js | 2 +-
2 files changed, 3 insertions(+), 1 deletion(-)
diff --git a/www/manager6/Utils.js b/www/manager6/Utils.js
index 3c15135..060643a 100644
--- a/www/manager6/Utils.js
+++ b/www/manager6/Utils.js
@@ -103,6 +103,8 @@ Ext.define('PVE.Utils', { statics: {
toolkit: undefined, // (extjs|touch), set inside Toolkit.js
+ bus_match: /^(ide|sata|virtio|scsi)\d+$/,
+
log_severity_hash: {
0: "panic",
1: "alert",
diff --git a/www/manager6/qemu/BootOrderEdit.js b/www/manager6/qemu/BootOrderEdit.js
index e6a9b9c..3dc4e75 100644
--- a/www/manager6/qemu/BootOrderEdit.js
+++ b/www/manager6/qemu/BootOrderEdit.js
@@ -9,7 +9,7 @@ Ext.define('PVE.qemu.BootOrderPanel', {
comboboxes: [],
isBootDisk: function(value) {
- return (/^(ide|sata|scsi|virtio)\d+$/).test(value);
+ return PVE.Utils.bus_match.test(value);
},
setVMConfig: function(vmconfig) {
--
2.1.4
More information about the pve-devel
mailing list