blob: 07d97955762c1d440432d3fdf17adba13ed64feb [file] [log] [blame]
<div class="tab-pane fade" id="tab-routing" role="tabpanel" aria-labelledby="tab-routing">
<div class="card mb-4">
<div class="card-header d-flex fs-5">
<button class="btn d-md-none flex-grow-1 text-start" data-bs-target="#collapse-tab-routing" data-bs-toggle="collapse" aria-controls="collapse-tab-routing">
{{ lang.admin.relayhosts }}
</button>
<span class="d-none d-md-block">{{ lang.admin.relayhosts }}</span>
</div>
<div id="collapse-tab-routing" class="card-body collapse" data-bs-parent="#admin-content">
<p class="mb-4">{{ lang.admin.relayhosts_hint|raw }}</p>
<table id="relayhoststable" class="table table-striped dt-responsive w-100"></table>
<div class="mass-actions-admin mb-4">
<div class="btn-group btn-group-sm">
<button type="button" id="toggle_multi_select_all" data-id="rlyhosts" class="btn btn-sm btn-xs-half d-block d-sm-inline btn-secondary">{{ lang.mailbox.toggle_all }}</button>
<a class="btn btn-sm btn-xs-half d-block d-sm-inline btn-secondary dropdown-toggle" data-bs-toggle="dropdown" href="#">{{ lang.mailbox.quick_actions }}</a>
<ul class="dropdown-menu top100">
<li><a class="dropdown-item" data-action="edit_selected" data-id="rlyhosts" data-api-url='edit/relayhost' data-api-attr='{"active":"1"}' href="#">{{ lang.mailbox.activate }}</a></li>
<li><a class="dropdown-item" data-action="edit_selected" data-id="rlyhosts" data-api-url='edit/relayhost' data-api-attr='{"active":"0"}' href="#">{{ lang.mailbox.deactivate }}</a></li>
<li><hr class="dropdown-divider"></li>
<li><a class="dropdown-item" data-action="delete_selected" data-id="rlyhosts" data-api-url='delete/relayhost' href="#">{{ lang.admin.remove }}</a></li>
</ul>
</div>
</div>
<legend>{{ lang.admin.add_relayhost }}</legend><hr />
<p class="text-muted">{{ lang.admin.add_relayhost_hint|raw }}</p>
<div class="row">
<div class="col-md-8">
<form class="form" data-id="rlyhost" role="form" method="post">
<div class="mb-2">
<label for="rlyhost_hostname">{{ lang.admin.host }}</label>
<input class="form-control" id="rlyhost_hostname" name="hostname" placeholder='[0.0.0.0], [0.0.0.0]:25, host:25, host, [host]:25' required>
</div>
<div class="mb-2">
<label for="rlyhost_username">{{ lang.admin.username }}</label>
<input class="form-control" id="rlyhost_username" name="username">
</div>
<div class="mb-4">
<label for="rlyhost_password">{{ lang.admin.password }}</label>
<input class="form-control" id="rlyhost_password" name="password" type="password">
</div>
<button class="btn btn-sm d-block d-sm-inline btn-success" data-action="add_item" data-id="rlyhost" data-api-url='add/relayhost' data-api-attr='{}' href="#"><i class="bi bi-plus-lg"></i> {{ lang.admin.add }}</button>
</form>
</div>
</div>
</div>
</div>
<div class="card mb-4">
<div class="card-header d-flex">
<button class="btn d-md-none flex-grow-1 text-start" data-bs-target="#collapse-tab-maps" data-bs-toggle="collapse" aria-controls="collapse-tab-maps">
{{ lang.admin.transport_maps }}
</button>
<span class="d-none d-md-block">{{ lang.admin.transport_maps }}</span>
</div>
<div id="collapse-tab-maps" class="card-body collapse" data-bs-parent="#admin-content">
<p style="margin-bottom:40px">{{ lang.admin.transports_hint|raw }}</p>
<table id="transportstable" class="table table-striped dt-responsive w-100"></table>
<div class="mass-actions-admin mb-4">
<div class="btn-group btn-group-sm">
<button type="button" id="toggle_multi_select_all" data-id="transports" class="btn btn-sm btn-xs-half d-block d-sm-inline btn-secondary">{{ lang.mailbox.toggle_all }}</button>
<a class="btn btn-sm btn-xs-half d-block d-sm-inline btn-secondary dropdown-toggle" data-bs-toggle="dropdown" href="#">{{ lang.mailbox.quick_actions }}</a>
<ul class="dropdown-menu top100">
<li><a class="dropdown-item" data-action="edit_selected" data-id="transports" data-api-url='edit/transport' data-api-attr='{"active":"1"}' href="#">{{ lang.mailbox.activate }}</a></li>
<li><a class="dropdown-item" data-action="edit_selected" data-id="transports" data-api-url='edit/transport' data-api-attr='{"active":"0"}' href="#">{{ lang.mailbox.deactivate }}</a></li>
<li><hr class="dropdown-divider"></li>
<li><a class="dropdown-item" data-action="delete_selected" data-id="transports" data-api-url='delete/transport' href="#">{{ lang.admin.remove }}</a></li>
</ul>
</div>
</div>
<legend>{{ lang.admin.add_transport }}</legend><hr />
<p class="text-muted">{{ lang.admin.add_transports_hint|raw }}</p>
<div class="row">
<div class="col-md-8">
<form class="form" data-id="transport" role="form" method="post">
<div class="mb-2">
<label for="transport_destination">{{ lang.admin.destination }}</label>
<input class="form-control" id="transport_destination" name="destination" placeholder='{{ lang.admin.transport_dest_format }}' required>
</div>
<div class="mb-2">
<label for="transport_nexthop">{{ lang.admin.nexthop }}</label>
<input class="form-control" id="transport_nexthop" name="nexthop" placeholder='host:25, host, [host]:25, [0.0.0.0]:25' required>
</div>
<div class="mb-2">
<label for="transport_username">{{ lang.admin.username }}</label>
<input class="form-control" id="transport_username" name="username">
</div>
<div class="mb-4">
<label for="transport_password">{{ lang.admin.password }}</label>
<input class="form-control" id="transport_password" name="password" type="password">
</div>
<div class="mb-2">
<label>
<input type="checkbox" class="form-check-input" name="is_mx_based" value="1"> {{ lang.admin.lookup_mx|raw }}
</label>
</div>
<div class="mb-4">
<label>
<input type="checkbox" class="form-check-input" name="active" value="1"> {{ lang.admin.active }}
</label>
</div>
<p class="text-muted">{{ lang.admin.credentials_transport_warning|raw }}</p>
<button class="btn btn-sm d-block d-sm-inline btn-success" data-action="add_item" data-id="transport" data-api-url='add/transport' data-api-attr='{}' href="#"><i class="bi bi-plus-lg"></i> {{ lang.admin.add }}</button>
</form>
</div>
</div>
</div>
</div>
</div>