create_aio
This commit is contained in:
23
internal/admin/tpl/partials_peers.html
Normal file
23
internal/admin/tpl/partials_peers.html
Normal file
@@ -0,0 +1,23 @@
|
||||
<div style="display:flex; justify-content:space-between; align-items:center">
|
||||
<h3 style="margin:0">Mesh Peers</h3>
|
||||
<form hx-post="/admin/mesh/syncnow" hx-target="#peers" hx-get="/admin/peers" hx-swap="outerHTML">
|
||||
<button class="btn btn-primary" type="submit">Jetzt synchronisieren</button>
|
||||
</form>
|
||||
</div>
|
||||
<div id="peers" style="margin-top:10px">
|
||||
<table>
|
||||
<thead><tr><th>URL</th><th>Self</th><th>Last Seen</th></tr></thead>
|
||||
<tbody>
|
||||
{{ range .Peers }}
|
||||
<tr>
|
||||
<td>{{ .URL }}</td>
|
||||
<td>{{ if .Self }}✅{{ else }}—{{ end }}</td>
|
||||
<td><small class="muted">{{ .LastSeen }}</small></td>
|
||||
</tr>
|
||||
{{ else }}
|
||||
<tr><td colspan="3" class="muted">Keine Peers bekannt.</td></tr>
|
||||
{{ end }}
|
||||
</tbody>
|
||||
</table>
|
||||
<div class="muted" style="margin-top:8px"><small>Stand: {{ .Now }}</small></div>
|
||||
</div>
|
||||
Reference in New Issue
Block a user