Skip to content
Snippets Groups Projects
Commit 7cdf8572 authored by Julian's avatar Julian
Browse files

Enabled admins to creates invite links for all roles, fixes #61

parent fd043890
No related branches found
No related tags found
No related merge requests found
......@@ -64,7 +64,11 @@ def index():
@invite_acl_required
def new():
user = get_current_user()
allow_signup = user.is_in_group(current_app.config['ACL_SIGNUP_GROUP']) or user.is_in_group(current_app.config['ACL_ADMIN_GROUP'])
if user.is_in_group(current_app.config['ACL_ADMIN_GROUP']):
allow_signup = True
roles = Role.query.all()
else:
allow_signup = user.is_in_group(current_app.config['ACL_SIGNUP_GROUP'])
roles = Role.query.filter(Role.moderator_group_dn.in_(user.group_dns)).all()
return render_template('invite/new.html', roles=roles, allow_signup=allow_signup)
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment