Remove chart when nothing to show.

This commit is contained in:
Sander Dorigo 2014-10-14 07:27:06 +02:00
parent b7517b49ed
commit aceb683d07

View File

@ -212,6 +212,9 @@ $(function () {
});
$.getJSON('chart/home/recurring').success(function (data) {
if (data[0].data.length == 0) {
$('#recurring').parent().parent().remove();
} else {
$('#recurring').highcharts({
title: {
text: null
@ -247,6 +250,7 @@ $(function () {
},
series: data
});
}
});
});