示例#1
0
文件: admin.py 项目: cgtobi/dudel
def admin_users():
    current_user.require_admin()
    users = User.query.order_by(db.asc(User.username)).all()
    return render_template("admin/users.html", users=users)
示例#2
0
def admin_groups():
    current_user.require_admin()
    groups = Group.query.order_by(db.asc(Group.name)).all()
    return render_template("admin/groups.html", groups=groups)
示例#3
0
 def get_comments(self):
     return Comment.query.filter_by(poll=self, deleted=False).order_by(db.asc(Comment.created)).all()
示例#4
0
def admin_users():
    current_user.require_admin()
    users = User.query.order_by(db.asc(User.username)).all()
    return render_template("admin/users.html", users=users)
示例#5
0
文件: poll.py 项目: opatut/dudel
 def get_comments(self):
     return Comment.query.filter_by(poll=self, deleted=False).order_by(
         db.asc(Comment.created)).all()