From 0d451687c2b3470562d2ef9d855b7cd502d65541 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Andr=C3=A9=20Gl=C3=BCpker?= Date: Sat, 24 Mar 2018 15:22:08 +0100 Subject: Display minutes for connection duration --- main.py | 6 ++---- templates/server_html.jinja | 6 +++--- 2 files changed, 5 insertions(+), 7 deletions(-) diff --git a/main.py b/main.py index 9ae9b54..2a1f51b 100755 --- a/main.py +++ b/main.py @@ -175,10 +175,8 @@ def server(): for name, server in servers.items(): server['data'] = QueryServer.QueryServer(server['ip'], server['port'], server['gameid']) return render_template('server_html.jinja', - servers=servers - # profiles=premadedata, - # display_time=display_time, - # connections=connections + servers=servers, + display_time = display_time ) if __name__ == '__main__': diff --git a/templates/server_html.jinja b/templates/server_html.jinja index e22eb29..0306d13 100644 --- a/templates/server_html.jinja +++ b/templates/server_html.jinja @@ -32,15 +32,15 @@ {% if info['data']['players'] %} - + - + {% for player in info['data']['player_info'] | sort(attribute='score', reverse=True) %} - + {% endfor %}
NameName ScoreTimeTime
{{ player['name'] }} {{ player['score'] }}{{ player['duration'] }}s{{ display_time(player['duration']) }}s
-- cgit v1.2.3