summaryrefslogtreecommitdiff
path: root/ishtar_common/templates
diff options
context:
space:
mode:
authorÉtienne Loks <etienne.loks@iggdrasil.net>2018-01-29 14:57:27 +0100
committerÉtienne Loks <etienne.loks@iggdrasil.net>2018-01-29 14:57:27 +0100
commit10bb75c89ed2eeb27255eafcde011bf2d425b1e4 (patch)
treebead0d5d13896280b163474ee2676dc01ee9f5ff /ishtar_common/templates
parentcf4b3bc0c6b99ed6260ae5964b9b67396415eaab (diff)
downloadIshtar-10bb75c89ed2eeb27255eafcde011bf2d425b1e4.tar.bz2
Ishtar-10bb75c89ed2eeb27255eafcde011bf2d425b1e4.zip
Dashboard: fix dynamic load
Diffstat (limited to 'ishtar_common/templates')
-rw-r--r--ishtar_common/templates/ishtar/dashboards/dashboard_main.html2
-rw-r--r--ishtar_common/templates/ishtar/dashboards/dashboard_main_detail.html7
2 files changed, 6 insertions, 3 deletions
diff --git a/ishtar_common/templates/ishtar/dashboards/dashboard_main.html b/ishtar_common/templates/ishtar/dashboards/dashboard_main.html
index f2eefd6d3..692e435a3 100644
--- a/ishtar_common/templates/ishtar/dashboards/dashboard_main.html
+++ b/ishtar_common/templates/ishtar/dashboards/dashboard_main.html
@@ -17,7 +17,7 @@
$(function() {
$('#dashboard .nav-link').click(function () {
var url = $(this).attr('data-url');
- $("#dashboard .card-body").load(url);
+ dynamic_load(url, "#dashboard .card-body");
$('#dashboard li').removeClass('active');
$('#dashboard li').removeClass('show');
$(this).parent().tab('show');
diff --git a/ishtar_common/templates/ishtar/dashboards/dashboard_main_detail.html b/ishtar_common/templates/ishtar/dashboards/dashboard_main_detail.html
index ac779abe0..0f33f2069 100644
--- a/ishtar_common/templates/ishtar/dashboards/dashboard_main_detail.html
+++ b/ishtar_common/templates/ishtar/dashboards/dashboard_main_detail.html
@@ -177,8 +177,11 @@ $(document).ready(function(){
if (typeof values_1_{{unique_id}} === 'undefined'
|| values_1_{{unique_id}}.length == 0){
-$('#chart_img_{{unique_id}}').hide();
-$('#chart_{{unique_id}}').html("<p class='alert'><i class='fa fa-exclamation-triangle' aria-hidden='true'></i> {% trans 'No data for these criteria.' %}</p>");
+ $('#chart_img_{{unique_id}}').hide();
+ $('#chart_{{unique_id}}').html(
+ "<p class='alert alert-warning'>{% trans 'No data for these criteria.' %}</p>"
+ );
+ $('#chart_{{unique_id}}').css('height', 'auto');
} else {
var showmarker = false;