Update system_counts.php (#6124)

This commit is contained in:
AlexC 2021-11-12 12:55:33 -07:00 committed by GitHub
parent 97ef7a5346
commit ed57bf9fc2
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 45 additions and 46 deletions

View File

@ -289,18 +289,17 @@
echo "<div class='hud_box'>\n";
if ($show_stat) {
echo "
//add doughnut chart
?>
<div style='display: flex; flex-wrap: wrap; justify-content: center; padding-bottom: 10px;'>
<div style='width: 250px; height: 175px;'><canvas id='system_count_chart'></canvas></div>
</div>
<script>
var system_count_bgc = ['#d4d4d4', '#2a9df4'];
const system_count_data = {
labels: ['InActive: ".$domain_inactive."', 'Active: ".$domain_active."'],
labels: ['InActive: <?php echo $domain_inactive; ?>', 'Active: <?php echo $domain_active; ?>'],
datasets: [{
data:[".$domain_inactive.", ".$domain_active."],
data: ['<?php echo $domain_inactive; ?>', '<?php echo $domain_active; ?>'],
borderColor: 'rgba(0,0,0,0)',
backgroundColor: ['#d4d4d4', '#2a9df4'],
cutout: chart_cutout
@ -315,7 +314,7 @@
maintainAspectRatio: false,
plugins: {
chart_counter: {
chart_text: ".$domain_total."
chart_text: '<?php echo $domain_total; ?>'
},
legend: {
position: 'right',
@ -327,7 +326,7 @@
},
title: {
display: true,
text: '".$text['label-system_counts']."'
text: '<?php echo $text['label-system_counts']; ?>'
}
}
},
@ -339,7 +338,7 @@
system_count_config
);
</script>
";
<?php
}
echo "<div class='hud_details hud_box' id='hud_system_counts_details'>";