[pve-devel] [PATCH manager 06/10] Use the noVirtiIO ControllerSelector property to build the list of controllers

Emmanuel Kasper e.kasper at proxmox.com
Wed Sep 6 10:15:36 CEST 2017


---
 www/manager6/form/ControllerSelector.js | 7 ++-----
 1 file changed, 2 insertions(+), 5 deletions(-)

diff --git a/www/manager6/form/ControllerSelector.js b/www/manager6/form/ControllerSelector.js
index 15023a7a..5c6631b3 100644
--- a/www/manager6/form/ControllerSelector.js
+++ b/www/manager6/form/ControllerSelector.js
@@ -61,9 +61,9 @@ Ext.define('PVE.form.ControllerSelector', {
 	var bussel = me.down('field[name=controller]');
 	var deviceid = me.down('field[name=deviceid]');
 
-	if (autoSelect === 'cdrom') {
+	if (me.noVirtiIO) {
 	    clist = ['ide', 'scsi', 'sata'];
-	    if (!Ext.isDefined(me.vmconfig.ide2)) {
+	    if (autoSelect === 'cdrom' && !Ext.isDefined(me.vmconfig.ide2)) {
 		bussel.setValue('ide');
 		deviceid.setValue(2);
 		return;
@@ -76,9 +76,6 @@ Ext.define('PVE.form.ControllerSelector', {
 
 	Ext.Array.each(clist, function(controller) {
 	    var confid, i;
-	    if (controller === 'virtio' && me.noVirtIO) {
-		return; //continue
-	    }
 	    bussel.setValue(controller);
 	    for (i = 0; i <= PVE.form.ControllerSelector.maxIds[controller]; i++) {
 		confid = controller + i.toString();
-- 
2.11.0





More information about the pve-devel mailing list