Update chart.js v3 to v4 (#6529)

* Update chart.min.js

* Update missed_calls.php

* Update recent_calls.php

* Update system_counts.php

* Update system_cpu_status.php

* Update system_status.php

* Update domain_limits.php

* Update voicemails.php
This commit is contained in:
Alex
2023-01-06 13:18:53 -07:00
committed by GitHub
parent 310d4d00e7
commit 37ab508d1b
9 changed files with 281 additions and 330 deletions

View File

@@ -71,43 +71,37 @@
</div>
<script>
var domain_limits_chart_context = document.getElementById('domain_limits_chart').getContext('2d');
const domain_limits_chart_data = {
datasets: [{
data:['<?php echo $hud_stat; ?>', 0.00001],
borderColor: 'rgba(0,0,0,0)',
backgroundColor: ['#2a9df4', '#d4d4d4'],
cutout: chart_cutout
}]
};
const domain_limits_chart_config = {
type: 'doughnut',
data: domain_limits_chart_data,
options: {
responsive: true,
maintainAspectRatio: false,
plugins: {
chart_counter: {
chart_text: '<?php echo $hud_stat; ?>',
},
legend: {
display: false
},
title: {
display: true,
text: '<?php echo $text['label-domain_limits']; ?>',
fontFamily: chart_text_font
}
}
},
plugins: [chart_counter],
};
const domain_limits_chart = new Chart(
domain_limits_chart_context,
domain_limits_chart_config
document.getElementById('domain_limits_chart').getContext('2d'),
{
type: 'doughnut',
data: {
datasets: [{
data:['<?php echo $hud_stat; ?>', 0.00001],
borderColor: 'rgba(0,0,0,0)',
backgroundColor: ['#2a9df4', '#d4d4d4'],
cutout: chart_cutout
}]
},
options: {
responsive: true,
maintainAspectRatio: false,
plugins: {
chart_counter: {
chart_text: '<?php echo $hud_stat; ?>',
},
legend: {
display: false
},
title: {
display: true,
text: '<?php echo $text['label-domain_limits']; ?>',
fontFamily: chart_text_font
}
}
},
plugins: [chart_counter],
}
);
</script>
<?php