Update stats mare
This commit is contained in:
parent
bbb370a605
commit
33590b23f5
2 changed files with 44 additions and 6 deletions
|
@ -1,9 +1,10 @@
|
||||||
<HTML>
|
<HTML>
|
||||||
<script src="https://cdnjs.cloudflare.com/ajax/libs/Chart.js/2.4.0/Chart.min.js"></script>
|
<script src="https://cdnjs.cloudflare.com/ajax/libs/Chart.js/2.4.0/Chart.min.js"></script>
|
||||||
<script type="text/javascript" src="./channelsstats.js"></script>
|
<script type="text/javascript" src="./channelsstats.js"></script>
|
||||||
<canvas id="myChart"></canvas>
|
<canvas id="byChannel"></canvas>
|
||||||
|
<canvas id="byTsunamy"></canvas>
|
||||||
<script>
|
<script>
|
||||||
var ctx = document.getElementById('myChart').getContext('2d');
|
var ctx = document.getElementById('byChannel').getContext('2d');
|
||||||
var chart = new Chart(ctx, {
|
var chart = new Chart(ctx, {
|
||||||
// The type of chart we want to create
|
// The type of chart we want to create
|
||||||
type: 'bar',
|
type: 'bar',
|
||||||
|
@ -11,7 +12,7 @@
|
||||||
// The data for our dataset
|
// The data for our dataset
|
||||||
data: {
|
data: {
|
||||||
labels: ['Janvier', 'Fevrier', 'Mars', 'Avril', 'Mai', 'Juin', 'Juillet', 'Aout', 'Septembre', 'Octobre', 'Novembre'],
|
labels: ['Janvier', 'Fevrier', 'Mars', 'Avril', 'Mai', 'Juin', 'Juillet', 'Aout', 'Septembre', 'Octobre', 'Novembre'],
|
||||||
datasets: data,
|
datasets: messagesByChannel,
|
||||||
},
|
},
|
||||||
|
|
||||||
// Configuration options go here
|
// Configuration options go here
|
||||||
|
@ -21,9 +22,45 @@
|
||||||
},
|
},
|
||||||
title: {
|
title: {
|
||||||
display: true,
|
display: true,
|
||||||
text: title,
|
text: "Nombre de message par canaux (" + updated +")",
|
||||||
position: "bottom"
|
position: "bottom"
|
||||||
},
|
},
|
||||||
|
responsive: true,
|
||||||
|
scales: {
|
||||||
|
xAxes: [{
|
||||||
|
stacked: true
|
||||||
|
}],
|
||||||
|
yAxes: [{
|
||||||
|
stacked: true,
|
||||||
|
ticks: {
|
||||||
|
stepSize: 500
|
||||||
|
}
|
||||||
|
}]
|
||||||
|
}
|
||||||
|
}
|
||||||
|
});
|
||||||
|
var ctx2 = document.getElementById('byTsunamy').getContext('2d');
|
||||||
|
var chart2 = new Chart(ctx2, {
|
||||||
|
// The type of chart we want to create
|
||||||
|
type: 'bar',
|
||||||
|
|
||||||
|
// The data for our dataset
|
||||||
|
data: {
|
||||||
|
labels: ['Janvier', 'Fevrier', 'Mars', 'Avril', 'Mai', 'Juin', 'Juillet', 'Aout', 'Septembre', 'Octobre', 'Novembre'],
|
||||||
|
datasets: messagesByTsunami,
|
||||||
|
},
|
||||||
|
|
||||||
|
// Configuration options go here
|
||||||
|
options: {
|
||||||
|
legend: {
|
||||||
|
display: false
|
||||||
|
},
|
||||||
|
title: {
|
||||||
|
display: true,
|
||||||
|
text: "Nombre de message par Tsunami (" + updated +")",
|
||||||
|
position: "bottom"
|
||||||
|
},
|
||||||
|
responsive: true,
|
||||||
scales: {
|
scales: {
|
||||||
xAxes: [{
|
xAxes: [{
|
||||||
stacked: true
|
stacked: true
|
||||||
|
|
File diff suppressed because one or more lines are too long
Loading…
Reference in a new issue