27 lines
1.4 KiB
HTML
27 lines
1.4 KiB
HTML
{{define "content"}}
|
|
<div class="container marketing">
|
|
<h3 class="text-center mb-4">DNS Host Entries</h3>
|
|
<table class="table table-striped text-center">
|
|
<thead>
|
|
<tr>
|
|
<th>Hostname</th>
|
|
<th>IP</th>
|
|
<th>TTL</th>
|
|
<th>LastUpdate</th>
|
|
<th><button class="btn btn-primary" onclick="location.href='/hosts/add'">Add Host Entry</button></th>
|
|
</tr>
|
|
</thead>
|
|
<tbody>
|
|
{{range .hosts}}
|
|
<tr>
|
|
<td>{{.Hostname}}.{{$.config.Domain}}</td>
|
|
<td>{{.Ip}}</td>
|
|
<td>{{.Ttl}}</td>
|
|
<td>{{.LastUpdate.Format "01/02/2006 15:04 MEZ"}}</td>
|
|
<td><button onclick="location.href='/hosts/edit/{{.ID}}'" class="btn btn-outline-secondary btn-sm"><img src="/static/icons/pencil.svg" alt="" width="16" height="16" title="Edit"></button> <button class="btn btn-outline-secondary btn-sm" onclick="deleteHost('{{.ID}}')"><img src="/static/icons/trash.svg" alt="" width="16" height="16" title="Delete"></button> <button class="btn btn-outline-secondary btn-sm" onclick="location.href='/logs/host/{{.ID}}'"><img src="/static/icons/table.svg" alt="" width="16" height="16" title="Logs"></button></td>
|
|
</tr>
|
|
{{end}}
|
|
</tbody>
|
|
</table>
|
|
</div>
|
|
{{end}} |