summaryrefslogtreecommitdiff
path: root/app
diff options
context:
space:
mode:
authorRené 'Necoro' Neumann <necoro@necoro.net>2014-08-28 00:55:22 +0200
committerRené 'Necoro' Neumann <necoro@necoro.net>2014-08-28 00:55:22 +0200
commit91f69a2754b38ea4583ef240f589d4da97f55c9d (patch)
treef6cda5c7ecdf224fb7b896a14131fc2e34d0118c /app
parent93cd07c81463959b7281a10557ea1d9471b97322 (diff)
downloadkosten-91f69a2754b38ea4583ef240f589d4da97f55c9d.tar.gz
kosten-91f69a2754b38ea4583ef240f589d4da97f55c9d.tar.bz2
kosten-91f69a2754b38ea4583ef240f589d4da97f55c9d.zip
Add clickable stat points
Diffstat (limited to '')
-rw-r--r--app/views/stats.py10
1 files changed, 10 insertions, 0 deletions
diff --git a/app/views/stats.py b/app/views/stats.py
index 90f1686..83c8154 100644
--- a/app/views/stats.py
+++ b/app/views/stats.py
@@ -8,6 +8,7 @@ from ..model import ConstExpense
import sqlalchemy as sql
import calendar
from collections import defaultdict
+from flask import jsonify
mod = Blueprint('stats', __name__)
@@ -20,6 +21,15 @@ def next_date(d):
def date_to_ms(d):
return calendar.timegm(d.timetuple()) * 1000
+@mod.route('/_const/<int(fixed_digits=4):year>/<int(fixed_digits=2):month>')
+@login_required
+@templated
+def const_dialog(year,month):
+ consts = ConstExpense.of_month(current_user, month, year).order_by(ConstExpense.description)
+
+ return { 'consts': consts }
+
+
@mod.route('/')
@login_required
@templated
class='deletions'>-0/+9 2009-08-11Do not show masking label, if the package is not in system anymoreRené 'Necoro' Neumann1-2/+2 2009-08-11Update turkish translationGürkan Gür1-640/+676 2009-08-11Fix handling of slots in /etc/portage/*René 'Necoro' Neumann2-2/+4 2009-08-11Fix package detailsRené 'Necoro' Neumann1-1/+1 2009-08-11Fix GPytage pluginRené 'Necoro' Neumann1-2/+2 2009-08-11Update translationRené 'Necoro' Neumann2-1112/+1120 2009-08-11Update changelogRené 'Necoro' Neumann1-0/+1 2009-08-10Fixed pt_BR translationAlberto Federman Neto1-2/+5 2009-08-10Add credits for translationRené 'Necoro' Neumann2-0/+2