2021-09-11 14:09:05 +00:00
|
|
|
{% load i18n %}
|
|
|
|
<script>
|
2021-10-04 17:42:02 +00:00
|
|
|
const labels = [{% for label in registration_stats.labels %}"{{ label }}",{% endfor %}];
|
2021-09-11 14:09:05 +00:00
|
|
|
const data = {
|
|
|
|
labels: labels,
|
|
|
|
datasets: [{
|
|
|
|
label: '{% trans "Active this month" %}',
|
|
|
|
backgroundColor: 'rgb(75, 192, 192)',
|
|
|
|
borderColor: 'rgb(75, 192, 192)',
|
2021-10-04 17:42:02 +00:00
|
|
|
data: {{ register_stats.total }},
|
2021-09-11 14:09:05 +00:00
|
|
|
}]
|
|
|
|
};
|
|
|
|
|
|
|
|
const config = {
|
|
|
|
type: 'line',
|
|
|
|
data: data,
|
|
|
|
options: {}
|
|
|
|
};
|
|
|
|
|
|
|
|
var userStats = new Chart(
|
|
|
|
document.getElementById('user_stats'),
|
|
|
|
config
|
|
|
|
);
|
|
|
|
</script>
|