X-Git-Url: https://gerrit.opnfv.org/gerrit/gitweb?a=blobdiff_plain;f=dashboard%2Fsrc%2Ftemplates%2Fbooking%2Fquick_deploy.html;h=38294b2404d4055ae5c86ad28943363ce62064db;hb=b2c5b21679ff2411b44ea90faef5ccae90cafac0;hp=2c1a3d23b0e07282c2df57558f40c3d1e34741c5;hpb=c4993fe457a453b000920043d29b4ea5e3718c45;p=pharos-tools.git diff --git a/dashboard/src/templates/booking/quick_deploy.html b/dashboard/src/templates/booking/quick_deploy.html index 2c1a3d2..38294b2 100644 --- a/dashboard/src/templates/booking/quick_deploy.html +++ b/dashboard/src/templates/booking/quick_deploy.html @@ -116,6 +116,12 @@ $('#id_image').children().hide(); + for( var i = 0; i < drop.childNodes.length; i++ ) + { + drop.childNodes[i].disabled = true; // closest we can get on safari to hiding it outright + } + + var empty_map = {} for ( var i=0; i < drop.childNodes.length; i++ ) @@ -138,12 +144,13 @@ if( image_object.host_profile == host_pk && image_object.lab == lab_pk ) { drop.childNodes[i].style.display = "inherit"; + drop.childNodes[i].disabled = false; } } } } - $('#id_image').children().hide(); + imageHider(); $('#id_installer').children().hide(); $('#id_scenario').children().hide(); @@ -173,7 +180,13 @@ } targ_id = "#" + target; + $(targ_id).children().hide(); + + for (var i = 0; i < document.getElementById(target).childNodes.length; i++) + { + document.getElementById(target).childNodes[i].disabled = true; + } var drop = document.getElementById(master); var opts = target_filter[drop.options[drop.selectedIndex].value]; if (!opts) { @@ -190,6 +203,7 @@ for (var i = 0; i < document.getElementById(target).childNodes.length; i++) { if (document.getElementById(target).childNodes[i].value in opts && !(document.getElementById(target).childNodes[i].value in emptyMap) ) { document.getElementById(target).childNodes[i].style.display = "inherit"; + document.getElementById(target).childNodes[i].disabled = false; } } }