tfstated/pkg/webui/html/statesId.html
Julien Dessaux d40595cacb
All checks were successful
main / publish (push) Has been skipped
main / main (push) Successful in 4m36s
main / deploy (push) Has been skipped
feat(webui): open a currated version of the user accounts section to non admin users
2025-04-15 00:08:24 +02:00

42 lines
926 B
HTML

{{ define "main" }}
<h1>State</h1>
<p>
The state at path
<strong>{{ .State.Path }}</strong>
has
<strong>{{ len .Versions }}</strong>
versions and is currently
<strong>
{{ if eq .State.Lock nil }}
unlocked.
{{ else }}
<span class="tooltip">
locked.
<span class="tooltip-text">
{{ .State.Lock }}
</span>
</span>
{{ end }}
</strong>
</p>
<p>Use this page to inspect the existing versions.</p>
<article>
<table style="width:100%;">
<thead>
<tr>
<th>Created</th>
<th>By</th>
</tr>
</thead>
<tbody>
{{ range .Versions }}
<tr>
<td><a href="/versions/{{ .Id }}">{{ .Created }}</a></td>
<td><a href="/accounts/{{ .AccountId }}">{{ index $.Usernames .AccountId.String }}</a></td>
</tr>
{{ end }}
</tbody>
</table>
</article>
<a href="/states">Go back to the states list</a>
{{ end }}