Files
MeshTender/internal/web/templates/command_log.html
T
2026-06-20 13:24:07 -04:00

41 lines
1.5 KiB
HTML
Raw Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
{{define "title"}}Command log · {{.Repeater.Name}} · MeshTender{{end}}
{{define "content"}}
<section class="card">
<h1>Command log · {{.Repeater.Name}}</h1>
<p class="muted">
Commands grouped by console session (one modem connection). “Confirmed” means a reply came back;
no reply doesn't mean the command failed — it may have run without us hearing the response.
</p>
{{if .Sessions}}
{{range .Sessions}}
<div class="session">
<div class="session-head">
<strong>{{.SenderName}}</strong>
<span class="muted">· {{.StartedAt.Format "2006-01-02 15:04"}}{{if .EndedAt}}{{.EndedAt.Format "15:04"}}{{else}} · in progress{{end}}</span>
</div>
<div class="logtable-wrap">
<table class="logtable">
<thead><tr><th>When</th><th>Command</th><th>Confirmed</th><th>Response</th></tr></thead>
<tbody>
{{range .Entries}}
<tr>
<td class="muted">{{.SentAt.Format "15:04:05"}}</td>
<td><code>{{.CommandText}}</code></td>
<td>{{if .AckReceived}}<span class="badge ok">yes</span>{{else}}<span class="badge pending">no reply</span>{{end}}</td>
<td><code class="resp">{{if .ResponseText}}{{.ResponseText}}{{else}}—{{end}}</code></td>
</tr>
{{end}}
</tbody>
</table>
</div>
</div>
{{end}}
{{else}}
<p class="muted">No commands have been sent yet.</p>
{{end}}
<p><a class="backlink" href="/">← Back to dashboard</a></p>
</section>
{{end}}