diff options
author | rubenwardy <rw@rubenwardy.com> | 2018-05-29 23:15:41 +0100 |
---|---|---|
committer | rubenwardy <rw@rubenwardy.com> | 2018-05-29 23:15:41 +0100 |
commit | c80ea2c1b1175257b0f718d9d122a106d62a2169 (patch) | |
tree | e8609fc3728ee8cef46b3f587a8a3705a0f80a45 /app/views/meta.py | |
parent | edd51b86d0601bbdac04ceeabd6bff470397bb32 (diff) | |
download | cheatdb-c80ea2c1b1175257b0f718d9d122a106d62a2169.tar.xz |
Sort meta list, and packages on profile
Diffstat (limited to 'app/views/meta.py')
-rw-r--r-- | app/views/meta.py | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/app/views/meta.py b/app/views/meta.py index fe1a05a..9083289 100644 --- a/app/views/meta.py +++ b/app/views/meta.py @@ -22,13 +22,13 @@ from app.models import * @app.route("/metapackages/") def meta_package_list_page(): - mpackages = MetaPackage.query.order_by(db.desc(MetaPackage.name)).all() - return render_template("meta/list.html", mpackages=mpackages) + mpackages = MetaPackage.query.order_by(db.asc(MetaPackage.name)).all() + return render_template("meta/list.html", mpackages=mpackages) @app.route("/metapackages/<name>/") def meta_package_page(name): - mpackage = MetaPackage.query.filter_by(name=name).first() - if mpackage is None: - abort(404) + mpackage = MetaPackage.query.filter_by(name=name).first() + if mpackage is None: + abort(404) - return render_template("meta/view.html", mpackage=mpackage) + return render_template("meta/view.html", mpackage=mpackage) |