-
Notifications
You must be signed in to change notification settings - Fork 0
/
sam.txt
48 lines (48 loc) · 1.62 KB
/
sam.txt
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
<script>
var ctx = document.getElementById('barChart').getContext('2d');
var barChart = new Chart(ctx, {
type: 'bar',
data: {
labels: <?php echo json_encode($labels);?>,
datasets: [{
label: 'Registration Count',
data: <?php echo json_encode($data); ?>,
backgroundColor: 'rgba(75, 192, 192, 0.2)',
borderColor: 'rgba(75, 192, 192, 1)',
borderWidth: 1
}]
},
options: {
scales: {
x: {
beginAtZero: true,
stepSize: 1
},
y: {
beginAtZero: true
}
}
}
});
var dateCtx = document.getElementById('dateChart').getContext('2d');
var dateChart = new Chart(dateCtx, {
type: 'bar',
data: {
labels: <?php echo json_encode($dateLabels); ?>,
datasets: [{
label: 'Date Registration Count',
data: <?php echo json_encode($dateData); ?>,
backgroundColor: 'rgba(192, 75, 75, 0.2)',
borderColor: 'rgba(192, 75, 75, 1)',
borderWidth: 1
}]
},
options: {
scales: {
y: {
beginAtZero: true
}
}
}
});
</script>