summaryrefslogtreecommitdiffstats
path: root/gui/odr-dabmux-gui.py
diff options
context:
space:
mode:
authorMatthias P. Braendli <matthias.braendli@mpb.li>2015-03-15 19:23:39 +0100
committerMatthias P. Braendli <matthias.braendli@mpb.li>2015-06-19 10:26:02 +0200
commit752fa808e3f148f45b689a026f0e703c83b83d92 (patch)
tree3347c04c69e65a1945a3da1f9d61f9c441169611 /gui/odr-dabmux-gui.py
parentc31a5cab786b79dc781f80fa3f9dae8376a2ed84 (diff)
downloaddabmux-752fa808e3f148f45b689a026f0e703c83b83d92.tar.gz
dabmux-752fa808e3f148f45b689a026f0e703c83b83d92.tar.bz2
dabmux-752fa808e3f148f45b689a026f0e703c83b83d92.zip
Add a statistics page to gui
Diffstat (limited to 'gui/odr-dabmux-gui.py')
-rwxr-xr-xgui/odr-dabmux-gui.py11
1 files changed, 11 insertions, 0 deletions
diff --git a/gui/odr-dabmux-gui.py b/gui/odr-dabmux-gui.py
index 84331b5..19f3ae8 100755
--- a/gui/odr-dabmux-gui.py
+++ b/gui/odr-dabmux-gui.py
@@ -62,6 +62,17 @@ def index():
version = conf.get_mux_version(),
services = conf.get_services())
+@route('/stats')
+def index():
+ conf.load()
+
+ return template('stats',
+ version = conf.get_mux_version())
+
+@route('/stats.json')
+def stats_json():
+ return conf.get_stats_dict()
+
@route('/static/<filename:path>')
def send_static(filename):