Deplacement du graphe numero 200

This commit is contained in:
guimoz 2017-01-30 02:02:12 +01:00
parent 93a25ba2a9
commit c612d929ba
6 changed files with 48 additions and 48 deletions

View file

@ -395,9 +395,9 @@ def home():
def play():
ip = get_ip()
player = get_player_from_ip(ip)
if STATE == "down":
if "down" in STATE:
return render_template('down.html', user=player)
elif STATE == "launched":
elif "up" in STATE:
# Traitement de la requête de bannissement
if request.method == 'POST':
target_id = request.form['target_id']

View file

@ -14,3 +14,46 @@ function startTimer(duration, display) {
}
}, 1000);
}
$(function () {
Highcharts.chart('container', {
chart: {
plotBackgroundColor: null,
plotBorderWidth: 0,
plotShadow: false
},
title: {
text: 'Etat du Rezo',
align: 'center',
verticalAlign: 'middle',
y: 40
},
tooltip: {
pointFormat: '{series.name}: <b>{point.percentage:.1f}%</b>'
},
plotOptions: {
pie: {
dataLabels: {
enabled: true,
distance: -50,
style: {
fontWeight: 'bold',
color: 'white'
}
},
startAngle: -90,
endAngle: 90,
center: ['50%', '75%']
},
},
series: [{
type: 'pie',
name: 'Etat du Rezo',
innerSize: '50%',
data: [
['Tranchés', {{ stats[0] }}],
['Vivants', {{ stats[1] }}]
]
}]
});
});

View file

@ -20,50 +20,4 @@
</p>
{% endif %}
<div id="container" style="min-width: 310px; max-width: 600px; margin: 0 auto"></div>
<script type='text/javascript'>
$(function () {
Highcharts.chart('container', {
chart: {
plotBackgroundColor: null,
plotBorderWidth: 0,
plotShadow: false
},
title: {
text: 'Browser<br>shares<br>2015',
align: 'center',
verticalAlign: 'middle',
y: 40
},
tooltip: {
pointFormat: '{series.name}: <b>{point.percentage:.1f}%</b>'
},
plotOptions: {
pie: {
dataLabels: {
enabled: true,
distance: -50,
style: {
fontWeight: 'bold',
color: 'white'
}
},
startAngle: -90,
endAngle: 90,
center: ['50%', '75%']
},
},
series: [{
type: 'pie',
name: 'Etat du Rezo',
innerSize: '50%',
data: [
['Tranchés', {{ stats[0] }}],
['Vivants', {{ stats[1] }}]
]
}]
});
});
</script>
{% endblock %}

View file

@ -40,6 +40,7 @@
<div id="content_bottomright" class="corner">
</div>
<div id="footer">contact technique : <a href="mailto:roulette@metzquetaires.fr">roulette@metzquetaires.fr</a></div>
<div id="container" style="min-width: 310px; max-width: 600px; margin: 0 auto"></div>
</div>
</div>
</body>

View file

@ -39,6 +39,7 @@
<div id="content_bottomright" class="corner">
</div>
<div id="footer">contact technique : <a href="mailto:roulette@metzquetaires.fr">roulette@metzquetaires.fr</a></div>
<div id="container" style="min-width: 310px; max-width: 600px; margin: 0 auto"></div>
</div>
</div>
</body>

View file

@ -37,6 +37,7 @@
</div>
<div id="content_bottomright" class="corner">
</div>
<div id="container" style="min-width: 310px; max-width: 600px; margin: 0 auto"></div>
</div>
</div>
</body>