{% extends "base.html" %} {% block title %}Role Master{% endblock %} {% block header %}Role Master{% endblock %} {% block content %}
{% set total_roles = roles|length if roles else 0 %} {% set total_permissions = perms|length if perms else 0 %}
Access Control

Role Master

Create roles, update role names, assign permissions, and manage role access using Excel import/export.
Total Roles
{{ total_roles }}
Roles
{{ total_roles }}
Configured user roles
Available Permissions
{{ total_permissions }}
Can be assigned to roles
Current Search
{% if q %}Active{% else %}All{% endif %}
{% if q %} Filtered by "{{ q }}" {% else %} Showing all roles {% endif %}
Create Role
New Role
Add a role first, then assign its permission access from the role list.
Role Setup Tip
Keep role names clear and business-friendly, such as Sales Manager, Operations Head, Admin, or Finance Executive.
Search
Find Role
Search by role name.
Roles
Role Permission Matrix
Expand a role to update its name and manage assigned permissions.
{{ total_roles }} Role(s) Download Excel
{% if roles|length == 0 %}
No roles found
{% if q %} No role matched your search. Try clearing the filter. {% else %} Create your first role using the form on the left or upload an Excel file. {% endif %}
{% if q %} Clear Search {% else %} {% endif %}
{% else %}
{% for r in roles %}

Assign Permissions
Select permissions this role should have access to.
{{ r.permissions|length }} selected
{% for p in perms %}
{% else %}
No permissions available
Create permissions first from Permission Master.
{% endfor %}
Permission changes apply immediately after saving.
{% endfor %}
{% endif %}
{% endblock %}