{% comment %} Grouped permission checkbox widget for TenantRoleForm. Renders permissions grouped by app_label > model, with each verb as a checkbox. System permissions (from AppConfig) are shown as disabled checked boxes. Context: widget.grouped_choices — list of (app_label, [(model_verbose, [perm_dict, ...])]) widget.name — HTML input name {% endcomment %} {% load i18n %}
{% for app_label, models in widget.grouped_choices %}

{{ app_label }}

{% for model_verbose, perms in models %}
{{ model_verbose }}
{% for perm in perms %} {% endfor %}
{% endfor %}
{% empty %}

{% trans "No permissions available." %}

{% endfor %}