{# Define the columns #}
{% set columns = [
  {'name':'name',  'data':'name', 'title':_('Name'), 'className':'export text-nowrap all'},
  {'name':'type', 'data':'infra_type', 'title':_('Type'), 'className':'export'},
  {'name':'perm', 'data':'permission', 'title':_('Permission'), 'className':'export'},
  {'name':'owners', 'data':'owners', 'title':_('Owner'), 'className':'export', 'render': 'sspOwners', 'render_arg': currentuser.ROLE_ADMIN != currentuser.role},
  {'name':'manage', 'data':'manage_url', 'title':'', 'orderable':False, 'className': 'all', 'render':'sspManageButton'},
] %}
{% set label %}
  <span class="ssp-tooltip"
        data-bs-toggle="tooltip"
        data-bs-placement="right"
        title="{{ _("This area displays permission to infrastructure services (e.g. DNS and DHCP).") }}">
    {% trans %}Infrastructure{% endtrans %}
  </span>
{% endset %}
<DatatableCard id="infra-table" data={{ url_for('dashboard', 'infra.json', u=user.username) }} columns={{ columns }} empty_message={{ _("No infrastructure resources.") }} icon="bi-gear" label={{ label }} description={{ _("Infrastructure resources assigned to user %(name)s [%(username)s].", name=user.name, username=user.username) }} />
