diff --git a/static/stemp_abw/js/map_functions.js b/static/stemp_abw/js/map_functions.js index fc9aa2af..80da26f9 100644 --- a/static/stemp_abw/js/map_functions.js +++ b/static/stemp_abw/js/map_functions.js @@ -77,6 +77,24 @@ function execClickAction(e) { + String(layer.feature.id) + "/" $.get(url_js, function (data) { setTimeout(function () { + var result_chart = document.querySelector('.result-chart [id^=\"hc_\"]'); + if (result_chart !== null) { + $.ajax({ + url: '/stemp_abw/results/', + type: "GET", + success: function (data) { + if (data == null) { + var id=parseInt(result_chart.getAttribute('data-highcharts-chart')); + Highcharts.charts[id].showLoading('Das Szenario wurde verändert.
Für Ergebnisse bitte Simulation starten.'); + } + }, + error: function (page) { + console.log('error'); + showErrorPopup(); + }, + cache: false + }); + } eval(data); }, 250); }); diff --git a/templates/stemp_abw/popups/pop_result.html b/templates/stemp_abw/popups/pop_result.html index 2cb8f03a..af62ae1b 100644 --- a/templates/stemp_abw/popups/pop_result.html +++ b/templates/stemp_abw/popups/pop_result.html @@ -4,7 +4,7 @@ {% block values %}: {{ layer.pop_result }} EinwohnerInnen{% endblock %} {% block vis %} -
+
{{ chart }}
{% endblock%} \ No newline at end of file