summaryrefslogtreecommitdiffstats
path: root/dashboard/src/templates/resource
diff options
context:
space:
mode:
authorParker Berberian <pberberian@iol.unh.edu>2018-12-03 19:22:36 +0000
committerGerrit Code Review <gerrit@opnfv.org>2018-12-03 19:22:36 +0000
commitdac183ec44234cf42c5805596ad508bab703f1fd (patch)
tree98aad779352c202ee022a8f017dd17cad68d59fd /dashboard/src/templates/resource
parent259a327639c5e32e15ccce34c013eece72cd175c (diff)
parentd7e2fc7062a761e62335073bec6306c78f1471cc (diff)
Merge "Removed Vanilla Form Submission"
Diffstat (limited to 'dashboard/src/templates/resource')
-rw-r--r--dashboard/src/templates/resource/steps/meta_info.html8
-rw-r--r--dashboard/src/templates/resource/steps/pod_definition.html1
2 files changed, 7 insertions, 2 deletions
diff --git a/dashboard/src/templates/resource/steps/meta_info.html b/dashboard/src/templates/resource/steps/meta_info.html
index 389ff6d..b458842 100644
--- a/dashboard/src/templates/resource/steps/meta_info.html
+++ b/dashboard/src/templates/resource/steps/meta_info.html
@@ -14,5 +14,11 @@
{% endblock content %}
{% block onleave %}
-document.getElementById("resource_meta_form").submit();
+var ajaxForm = $("#resource_meta_form");
+var formData = ajaxForm.serialize();
+req = new XMLHttpRequest();
+req.open("POST", "/wf/workflow/", false);
+req.setRequestHeader("Content-Type", "application/x-www-form-urlencoded");
+req.onerror = function() { alert("problem submitting form"); }
+req.send(formData);
{% endblock %}
diff --git a/dashboard/src/templates/resource/steps/pod_definition.html b/dashboard/src/templates/resource/steps/pod_definition.html
index ab9dfb3..b2b4998 100644
--- a/dashboard/src/templates/resource/steps/pod_definition.html
+++ b/dashboard/src/templates/resource/steps/pod_definition.html
@@ -596,7 +596,6 @@ function submitForm() {
var input_elem = document.getElementById("hidden_xml_input");
var s = encodeGraph(currentGraph);
input_elem.value = s;
- //form.submit();
req = new XMLHttpRequest();
req.open("POST", "/wf/workflow/", false);
req.setRequestHeader("Content-Type", "application/x-www-form-urlencoded");