summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorParker Berberian <pberberian@iol.unh.edu>2018-12-05 16:13:13 +0000
committerGerrit Code Review <gerrit@opnfv.org>2018-12-05 16:13:13 +0000
commit9ae6c5c1cef2c5488b5c7c7700c886f8ebfe9d00 (patch)
treec2fad881e6b75795f758fd4f395ad86afdbdced9
parentdac183ec44234cf42c5805596ad508bab703f1fd (diff)
parentc8215477fe981edd6603ef825a1284a1ee2ff298 (diff)
Merge "Add Nav Button Disabling Behavior"
-rw-r--r--dashboard/src/templates/workflow/viewport-base.html27
1 files changed, 27 insertions, 0 deletions
diff --git a/dashboard/src/templates/workflow/viewport-base.html b/dashboard/src/templates/workflow/viewport-base.html
index fd9b638..37eff27 100644
--- a/dashboard/src/templates/workflow/viewport-base.html
+++ b/dashboard/src/templates/workflow/viewport-base.html
@@ -14,6 +14,9 @@
height: calc(100% - 170px);
}
+ .go_btn_disabled{
+ background-color: #ffffff;
+ }
.go_forward{
right: 0px;
border-left: none;
@@ -208,6 +211,30 @@
function update_breadcrumbs(meta_json) {
step = meta_json['active'];
page_count = meta_json['steps'].length;
+ if( step == 0 )
+ {
+ var btn = document.getElementById("gob");
+ btn.classList.add("go_btn_disabled");
+ btn.disabled = true;
+ }
+ else
+ {
+ var btn = document.getElementById("gob");
+ btn.classList.remove("go_btn_disabled");
+ btn.disabled = false;
+ }
+ if( step == page_count - 1 )
+ {
+ var btn = document.getElementById("gof");
+ btn.classList.add("go_btn_disabled");
+ btn.disabled = true;
+ }
+ else
+ {
+ var btn = document.getElementById("gof");
+ btn.classList.remove("go_btn_disabled");
+ btn.disabled = false;
+ }
//remove all children of breadcrumbs so we can redraw
var container = document.getElementById("breadcrumbs");
while(container.firstChild){