From ac0fe888b57a2cba9b2884590dc38e6680f54d22 Mon Sep 17 00:00:00 2001 From: Parker Berberian Date: Fri, 21 Jun 2019 17:08:56 -0400 Subject: Move JS to external file This is mostly a proof of concept to move all JS to external files to pave the way for future re-architecting Change-Id: I3b6f00bff7325b85a75d37f554892fa5283d9f4b Signed-off-by: Parker Berberian --- dashboard/src/templates/booking/quick_deploy.html | 8 +- .../dashboard/multiple_select_filter_widget.html | 274 +-------------------- .../templates/resource/steps/define_hardware.html | 15 +- 3 files changed, 15 insertions(+), 282 deletions(-) (limited to 'dashboard/src/templates') diff --git a/dashboard/src/templates/booking/quick_deploy.html b/dashboard/src/templates/booking/quick_deploy.html index ea80af4..07f3d89 100644 --- a/dashboard/src/templates/booking/quick_deploy.html +++ b/dashboard/src/templates/booking/quick_deploy.html @@ -83,7 +83,7 @@ function submit_form() { //formats data for form submission - document.getElementById("filter_field").value = JSON.stringify(result); + multi_filter_widget.finish(); } function hide_dropdown(drop_id) { @@ -104,10 +104,8 @@ } function get_selected_value(key){ - for( var attr in result[key] ){ - if( attr in {} ) - continue; - else + for( var attr in multi_filter_widget.result[key] ){ + if(!(attr in {}) ) return attr; } return null; diff --git a/dashboard/src/templates/dashboard/multiple_select_filter_widget.html b/dashboard/src/templates/dashboard/multiple_select_filter_widget.html index 3a7e148..bfcbed6 100644 --- a/dashboard/src/templates/dashboard/multiple_select_filter_widget.html +++ b/dashboard/src/templates/dashboard/multiple_select_filter_widget.html @@ -1,3 +1,6 @@ + +