Ejemplo n.º 1
0
def admin():
    """Super-admin page; allows roles to be changed. Don't advertise.
    Misuse will totally break everything."""
    aaa.require(role='admin', fail_redirect='/sorry_page')
    return dict(current_user=aaa.current_user,
                users=aaa.list_users(),
                roles=aaa.list_roles())
Ejemplo n.º 2
0
def admin():
    """Regular, more user-friendly admin."""
    aaa.require(role='admin', fail_redirect='/sorry_page')
    return dict(
        current_user=aaa.current_user,
        users=aaa.list_users(),
        roles=aaa.list_roles()
    )
Ejemplo n.º 3
0
def admin():
    """Super-admin page; allows roles to be changed. Don't advertise.
    Misuse will totally break everything."""
    aaa.require(role='admin', fail_redirect='/sorry_page')
    return dict(
        current_user=aaa.current_user,
        users=aaa.list_users(),
        roles=aaa.list_roles()
    )
Ejemplo n.º 4
0
def admin():
    """Regular, more user-friendly admin."""
    aaa.require(role='admin', fail_redirect='/sorry_page')
    return dict(current_user=aaa.current_user,
                users=aaa.list_users(),
                roles=aaa.list_roles())