diff --git a/digimarks.py b/digimarks.py index 7cdd186..a935fd4 100644 --- a/digimarks.py +++ b/digimarks.py @@ -426,9 +426,12 @@ def tags(userkey): total = Bookmark.select().where(Bookmark.userkey == userkey, Bookmark.tags.contains(tag), Bookmark.status == Bookmark.VISIBLE).count() alltags.append({'tag': tag, 'publictag': publictag, 'total': total}) totaltags = len(alltags) - totalbookmarks = Bookmark.select().where(Bookmark.userkey == userkey).count() + totalbookmarks = Bookmark.select().where(Bookmark.userkey == userkey, Bookmark.status == Bookmark.VISIBLE).count() totalpublic = PublicTag.select().where(PublicTag.userkey == userkey).count() - return render_template('tags.html', tags=alltags, totaltags=totaltags, totalpublic=totalpublic, totalbookmarks=totalbookmarks, userkey=userkey) + totaldeleted = Bookmark.select().where(Bookmark.userkey == userkey, Bookmark.status == Bookmark.DELETED).count() + totalstarred = Bookmark.select().where(Bookmark.userkey == userkey, Bookmark.starred == True).count() + return render_template('tags.html', tags=alltags, totaltags=totaltags, totalpublic=totalpublic, totalbookmarks=totalbookmarks, + totaldeleted=totaldeleted, totalstarred=totalstarred, userkey=userkey) @app.route('//tag/') diff --git a/templates/tags.html b/templates/tags.html index 03f4f56..4c6f9d6 100644 --- a/templates/tags.html +++ b/templates/tags.html @@ -5,37 +5,23 @@
- +
- - + + + + + - - - - - - - - - - + + + + +
 Totallabelpresent_to_allturned_instardelete
- Different tags - - {{ totaltags }} -
- Public tag pages - - {{ totalpublic }} -
- Bookmarks - - {{ totalbookmarks }} - {{ totaltags }}{{ totalpublic }}{{ totalbookmarks }}{{ totalstarred }}{{ totaldeleted }}