From 3a406f70cf855f7b9e8de67ad84b2cded9b91fad Mon Sep 17 00:00:00 2001 From: =?utf8?q?Felix=20D=C3=B6rre?= Date: Wed, 22 Nov 2017 15:04:46 +0100 Subject: [PATCH] add: display active user name --- motion.py | 1 + templates/index.html | 5 +++++ 2 files changed, 6 insertions(+) diff --git a/motion.py b/motion.py index f0318d2..783cf47 100644 --- a/motion.py +++ b/motion.py @@ -49,6 +49,7 @@ def lookup_user(): db.prepare("INSERT INTO voter(\"email\") VALUES($1)")(user) rv = db.prepare("SELECT id FROM voter WHERE email=$1")(user) g.voter = rv[0].get("id"); + g.user = user g.roles = {} for r in roles: diff --git a/templates/index.html b/templates/index.html index fdbb010..4ff3a44 100644 --- a/templates/index.html +++ b/templates/index.html @@ -3,6 +3,11 @@
{%- if categories|length != 0 %}
+
+
+User: {{g.user}} +
+
-- 2.39.2