Fix todo topics sort order

This commit is contained in:
rubenwardy 2018-06-02 19:44:57 +01:00
parent 389258a10c
commit 8e134a7c85
No known key found for this signature in database
GPG Key ID: A1E29D52FF81513C
2 changed files with 2 additions and 2 deletions

View File

@ -58,7 +58,7 @@ def todo_topics_page():
topics = KrockForumTopic.query \
.filter(~ db.exists().where(Package.forums==KrockForumTopic.topic_id)) \
.order_by(db.asc(KrockForumTopic.title)) \
.order_by(db.asc(KrockForumTopic.name), db.asc(KrockForumTopic.title)) \
.all()
return render_template("todo/topics.html", topics=topics, total=total)

View File

@ -101,7 +101,7 @@ def user_profile_page(username):
topics_to_add = KrockForumTopic.query \
.filter_by(author_id=user.id) \
.filter(~ db.exists().where(Package.forums==KrockForumTopic.topic_id)) \
.order_by(db.asc(KrockForumTopic.title)) \
.order_by(db.asc(KrockForumTopic.name), db.asc(KrockForumTopic.title)) \
.all()
# Process GET or invalid POST