2021-09-24 12:31:29 +00:00
|
|
|
{% extends "musician/mail_base.html" %}
|
|
|
|
{% load i18n %}
|
|
|
|
|
|
|
|
{% block tabcontent %}
|
|
|
|
<div class="tab-pane fade show active" id="mailboxes" role="tabpanel" aria-labelledby="mailboxes-tab">
|
|
|
|
<table class="table service-list">
|
|
|
|
<colgroup>
|
|
|
|
<col span="1" style="width: 20%;">
|
|
|
|
<col span="1" style="width: 10%;">
|
|
|
|
<col span="1" style="width: 60%;">
|
|
|
|
<col span="1" style="width: 10%;">
|
|
|
|
</colgroup>
|
|
|
|
<thead class="thead-dark">
|
|
|
|
<tr>
|
|
|
|
<th scope="col">{% trans "Name" %}</th>
|
|
|
|
<th scope="col">{% trans "Filtering" %}</th>
|
|
|
|
<th scope="col">{% trans "Addresses" %}</th>
|
2021-10-06 09:07:22 +00:00
|
|
|
<th scope="col"></th>
|
2021-09-24 12:31:29 +00:00
|
|
|
</tr>
|
|
|
|
</thead>
|
|
|
|
<tbody>
|
2021-09-27 10:40:52 +00:00
|
|
|
{% for mailbox in object_list %}
|
2021-10-06 09:07:22 +00:00
|
|
|
{# <!-- Exclude (don't render) inactive mailboxes -->#}
|
|
|
|
{% if mailbox.is_active %}
|
2021-09-24 12:31:29 +00:00
|
|
|
<tr>
|
|
|
|
<td>{{ mailbox.name }}</td>
|
|
|
|
<td>{{ mailbox.filtering }}</td>
|
2021-09-27 10:40:52 +00:00
|
|
|
<td>
|
|
|
|
{% for addr in mailbox.addresses %}
|
2021-09-27 11:52:27 +00:00
|
|
|
<a href="{% url 'musician:address-update' addr.data.id %}">
|
2021-09-27 10:40:52 +00:00
|
|
|
{{ addr.data.name }}@{{ addr.data.domain.name }}
|
|
|
|
</a><br/>
|
|
|
|
{% endfor %}
|
|
|
|
</td>
|
2021-10-06 09:07:22 +00:00
|
|
|
<td>
|
|
|
|
|
|
|
|
<a class="btn btn-outline-danger" href="{% url 'musician:mailbox-delete' mailbox.id %}" title="{% trans 'Delete' %}"><i class="fas fa-trash"></i></a>
|
|
|
|
</td>
|
2021-09-24 12:31:29 +00:00
|
|
|
</tr>
|
2021-10-06 09:07:22 +00:00
|
|
|
{% endif %}{# <!-- /is_active --> #}
|
2021-09-24 12:31:29 +00:00
|
|
|
{% endfor %}
|
|
|
|
</tbody>
|
|
|
|
{% include "musician/components/table_paginator.html" %}
|
2021-10-05 11:10:53 +00:00
|
|
|
</table>
|
|
|
|
<a class="btn btn-primary mt-4 mb-4" href="{% url 'musician:mailbox-create' %}">{% trans "New mailbox" %}</a>
|
|
|
|
|
2021-09-24 12:31:29 +00:00
|
|
|
</div>
|
|
|
|
{% endblock %}
|