From 47773eae78862b8346c5f328e0fa6b6cd71f9564 Mon Sep 17 00:00:00 2001 From: Leif Johansson Date: Tue, 17 Jan 2012 12:19:44 +0100 Subject: per-room usage statistics too --- src/templates/apps/stats/domain.html | 4 +++- src/templates/apps/stats/room.html | 32 ++++++++++++++++++++++++++++++++ src/templates/apps/stats/user.html | 2 +- 3 files changed, 36 insertions(+), 2 deletions(-) create mode 100644 src/templates/apps/stats/room.html (limited to 'src/templates/apps/stats') diff --git a/src/templates/apps/stats/domain.html b/src/templates/apps/stats/domain.html index 8f86976..93fb1a9 100644 --- a/src/templates/apps/stats/domain.html +++ b/src/templates/apps/stats/domain.html @@ -15,6 +15,7 @@ $.ajax({ }); $('#minutes').append(resp['minutes']); $('#rooms').append(resp['rooms']); + $('#users').append(resp['users']); } }); {% endblock %} @@ -26,7 +27,8 @@ $.ajax({ + +
Total minutes:
Total rooms:
Total unique users:
Look at your own statistics
-Look at your own statistics {% endblock %} \ No newline at end of file diff --git a/src/templates/apps/stats/room.html b/src/templates/apps/stats/room.html new file mode 100644 index 0000000..7a2a25f --- /dev/null +++ b/src/templates/apps/stats/room.html @@ -0,0 +1,32 @@ +{% extends "base.html" %} +{% load datehumanize %} +{% load prefix %} +{% block widgets %} +$.ajax({ + url: '{% prefix %}/api/stats/room/{{room.id}}', + method: 'GET', + success: function (resp) { + var graph = $('#graph'); + series = [{label: 'Meeting minutes for {{room.name}}',data: resp['data']}]; + $.plot(graph,series,{ + lines: { show: true }, + points: { show: true }, + xaxis: { mode: "time" } + }); + $('#minutes').append(resp['minutes']); + $('#users').append(resp['users']); + } +}); +{% endblock %} +{% block content %} +

Meeting statistics for {{room.name}}

+
+
+

Summary

+ + + + +
Total minutes:
Total unique users:
Look at your own statistics
+
+{% endblock %} \ No newline at end of file diff --git a/src/templates/apps/stats/user.html b/src/templates/apps/stats/user.html index 73c4fb9..486c9be 100644 --- a/src/templates/apps/stats/user.html +++ b/src/templates/apps/stats/user.html @@ -26,7 +26,7 @@ $.ajax({ +
Total minutes:
Total rooms:
Look at statistics for {{domain}}
-Look at statistics for {{domain}} {% endblock %} \ No newline at end of file -- cgit v1.1