Merge pull request #3288 from Icinga/bugfix/performance-problem-lots-of-performance-data-2894

Performance data: render pie charts without freezing the UI
This commit is contained in:
lippserd 2018-01-19 16:16:54 +01:00 committed by GitHub
commit 0b9ae48530
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 8 additions and 4 deletions

View File

@ -15,13 +15,17 @@
Sparkline.prototype.onRendered = function(e) {
$(e.target).find('.sparkline').each(function() {
$(this).sparkline('html', {
enableTagOptions: true,
disableTooltips: true
});
setTimeout(sparkline, 0, $(this));
});
};
Icinga.Behaviors.Sparkline = Sparkline;
function sparkline(selector) {
selector.sparkline('html', {
enableTagOptions: true,
disableTooltips: true
});
}
})(Icinga, jQuery);