From e448f69f3852147bd1df0859b7d521531fb8afe7 Mon Sep 17 00:00:00 2001 From: Michiel Scholten Date: Wed, 17 Aug 2016 16:48:06 +0200 Subject: [PATCH] Count notes --- digimarks.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/digimarks.py b/digimarks.py index 1166927..9420f4c 100644 --- a/digimarks.py +++ b/digimarks.py @@ -464,10 +464,11 @@ def tags(userkey): totalpublic = PublicTag.select().where(PublicTag.userkey == userkey).count() totalstarred = Bookmark.select().where(Bookmark.userkey == userkey, Bookmark.starred == True).count() totaldeleted = Bookmark.select().where(Bookmark.userkey == userkey, Bookmark.status == Bookmark.DELETED).count() + totalnotes = Bookmark.select().where(Bookmark.userkey == userkey, Bookmark.note != '').count() totalhttperrorstatus = Bookmark.select().where(Bookmark.userkey == userkey, Bookmark.http_status != 200).count() return render_template('tags.html', tags=alltags, totaltags=totaltags, totalpublic=totalpublic, totalbookmarks=totalbookmarks, totaldeleted=totaldeleted, totalstarred=totalstarred, totalhttperrorstatus=totalhttperrorstatus, - userkey=userkey) + totalnotes=totalnotes, userkey=userkey) @app.route('//tag/')