summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorSawyer Bergeron <sbergeron@iol.unh.edu>2019-04-10 12:31:55 -0400
committerSawyer Bergeron <sbergeron@iol.unh.edu>2019-04-10 12:31:55 -0400
commit13ae6962627f0afd8235127d0711c51215228fa7 (patch)
tree1e6b4edc55a29ea4d05138c59852edc76772fd0d
parent9c8ccc26cfbaae98e9ada79a9e26c64a576e71d4 (diff)
Fix dropdown visibility bug on Safari
Change-Id: Ibf9c61cc166f9717fa018946651668da748fe73b Signed-off-by: Sawyer Bergeron <sbergeron@iol.unh.edu>
-rw-r--r--dashboard/src/templates/booking/quick_deploy.html16
1 files changed, 15 insertions, 1 deletions
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;
}
}
}