Label WIP

This commit is contained in:
Jarek Radosz
2020-07-03 14:07:25 +02:00
parent 06dbeb679a
commit 686b46d207
6 changed files with 39 additions and 37 deletions
@@ -50,8 +50,9 @@ export default Component.extend({
},
didInsertElement() {
loadScript("/javascripts/Chart.min.js").then(() =>
this.refreshChart.apply(this)
);
loadScript("/javascripts/Chart.min.js").then(() => {
window.Chart.plugins.unregister(window.ChartDataLabels);
this.refreshChart.apply(this);
});
}
});
@@ -90,6 +90,7 @@ export default Component.extend({
}
loadScript("/javascripts/Chart.min.js").then(() => {
window.Chart.plugins.unregister(window.ChartDataLabels);
this._resetChart();
if (!this.element) {
@@ -67,6 +67,7 @@ export default Component.extend({
};
loadScript("/javascripts/Chart.min.js").then(() => {
window.Chart.plugins.unregister(window.ChartDataLabels);
this._resetChart();
this._chart = new window.Chart(context, this._buildChartConfig(data));