{% extends 'base.html' %}


{% block body %}
  <table class='table table-striped table-hover'>
    <thead class='thead-dark'>
      <tr>
        <th scope='col'>#</th>
        <th scope='col'>Mail</th>
        <th scope='col'>Nome</th>
        <th scope='col'>*</th>
        <th scope='col'>l</th>
        <th scope='col'>quota</th>
	{% if 'USERSHOWCLEARPASSWORD' in securitylist %}<th scope='col'>Password</th>{% endif %}
	<th scope='col'>Agg.Pas</th>
	<th scope='col'>Attivo</th>
	<th scope='col'>Da cancellare</th>
      </tr>
    </thead>
    <tbody>
      {% for u in userlist %}
      <tr class='{% if not u.enabled %} table-dark {% endif %}' >
	<th scope='row'>{{ u.id }}{% if u.securitylevel.id == 5 %} * {% endif %}</th>
        <td> {{ u.mail }} </td>
        <td> {{ u.nome }} </td>
        <td>{% if u.enabled %}*{% else %}-{% endif %}</td>
        <td>{{ u.securitylevel.id }}</td>
	<td>{{ u.mail_quota }}Mb/{% if u.warning_mail_quota %}{{ u.warning_mail_quota }}Mb{% else %}--{% endif %}
		{% if 'USERSHOWCLEARPASSWORD' in securitylist %} <td>{{ u.clear }}</td> {% endif %} 
        <td>{% if u.last_password_update %}{{ u.last_password_update }}{% endif %}</td>
        <td>{% if not u.enabled %}Utente Disattivato {% else %} {% endif %}</td>
	<td>{% if u.tobedeleted %}In Cancellazione {% else %} {% endif %} </td>
      </tr>
      {% endfor %}
    </tbody>

{% endblock %}


