Changed ratios to percentages
parent
611c4e1934
commit
9f3d7e7ae3
|
@ -43,10 +43,10 @@ def overview_data():
|
|||
|
||||
# Ratios
|
||||
data['ratio'] = {
|
||||
'accepted': data['total']['application']['accepted'] /
|
||||
data['total']['application']['denied'] if data['total']['application']['denied'] != 0 else 1,
|
||||
'banned': data['total']['player']['banned'] /
|
||||
data['total']['player']['unbanned'] if data['total']['player']['unbanned'] != 0 else 1
|
||||
'accepted': (data['total']['application']['accepted'] /
|
||||
data['total']['application']['denied'] if data['total']['application']['denied'] != 0 else 1) * 100,
|
||||
'banned': (data['total']['player']['banned'] /
|
||||
data['total']['player']['unbanned'] if data['total']['player']['unbanned'] != 0 else 1) * 100
|
||||
}
|
||||
|
||||
return data
|
||||
|
|
|
@ -40,10 +40,10 @@
|
|||
<hr/>
|
||||
<div class="row">
|
||||
<div class="col-xs-9 col-md-6">
|
||||
<h3>Acceptance Rate: {{ data.ratio.accepted }}</h3>
|
||||
<h3>Acceptance Rate: {{ data.ratio.accepted }}%</h3>
|
||||
</div>
|
||||
<div class="col-xs-9 col-md-6">
|
||||
<h3>Ban Rate: {{ data.ratio.banned }}</h3>
|
||||
<h3>Ban Rate: {{ data.ratio.banned }}%</h3>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
|
Loading…
Reference in New Issue