Skip to content
Snippets Groups Projects
Commit 3ec54162 authored by rixx's avatar rixx
Browse files

Show current user roles on self service page

Refs #54
parent a3ec8679
No related branches found
No related tags found
Loading
...@@ -40,6 +40,22 @@ ...@@ -40,6 +40,22 @@
<label for="user-password2">Password Repeat</label> <label for="user-password2">Password Repeat</label>
<input type="password" class="form-control" id="user-password2" name="password2" placeholder="●●●●●●●●"> <input type="password" class="form-control" id="user-password2" name="password2" placeholder="●●●●●●●●">
</div> </div>
<div class="form-group">
{% if user.roles_recursive|length %}
{% if user.roles_recursive|length == 1 %}
You have this role:
{% else %}
You currently have these roles:
{% endif %}
<ul>
{% for role in user.roles_recursive|sort(attribute="name") %}
<li>{{ role.name }}</li>
{% endfor %}
</ul>
{% else %}
You currently don't have any roles.
{% endif %}
</div>
<div class="form-group col-md-12"> <div class="form-group col-md-12">
<button type="submit" class="btn btn-primary float-right"><i class="fa fa-save" aria-hidden="true"></i> Save</button> <button type="submit" class="btn btn-primary float-right"><i class="fa fa-save" aria-hidden="true"></i> Save</button>
</div> </div>
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment