From deee82377a1f72626cede01fdfec5e9d7cc274ce Mon Sep 17 00:00:00 2001 From: Javier Garcia Date: Fri, 18 Sep 2015 13:33:33 +0200 Subject: [PATCH] SLA plugin: fixed template shown in dialog --- plugins/sladialog/static/js/sladialog.js | 65 +++++++++++++----------- sla/slicetabsla.py | 7 +-- 2 files changed, 38 insertions(+), 34 deletions(-) diff --git a/plugins/sladialog/static/js/sladialog.js b/plugins/sladialog/static/js/sladialog.js index a8f8244c..01eb0afd 100644 --- a/plugins/sladialog/static/js/sladialog.js +++ b/plugins/sladialog/static/js/sladialog.js @@ -27,12 +27,11 @@ this.listen_query(options.query_uuid); /* GUI setup and event binding */ - - // call function - this.button_binding(); - // Get testbeds with sla and store them in localStorage this.get_testbeds_with_sla(); + + // call function + //this.button_binding(); }, get_testbeds_with_sla: function () { @@ -50,36 +49,40 @@ }, get_sla_templates: function (testbeds) { + var self = this; testbeds.forEach(function(testbed, index, array) { - if(testbed!="omf:netmode") { return } // TODO: remove - - $.get('/sla/agreements/templates/' + testbed, function(slo) { - - $(".modal-body #sla_template").append(slo); - - var content = - "