morffix/tmpl/library.tmpl
speatzle 011f97a3e6
All checks were successful
/ release (push) Successful in 32s
Add Comand to Library
2024-10-08 16:42:25 +02:00

64 lines
1.7 KiB
Cheetah

{{template "head"}}
<h2>Library {{.Library.Name}}</h2>
<p>{{if .Library.Enable}}Enabled{{else}}Disabled{{end}}</p>
<h2>Files</h2>
<form method="POST" action="/scan/{{.Library.ID}}">
<label>Full:</label><br />
<input type="checkbox" name="full"><br />
<input value="Scan" type="submit">
<label for="health_command">Health Command:</label>
<select id="health_command" name="health_command">
{{range $l := .FfmpegCommands}}
<option value="{{$l.ID}}">{{$l.Name}}</option>
{{end}}
</select>
<label for="transcode_command">Transcode Command:</label>
<select id="transcode_command" name="transcode_command">
{{range $l := .FfmpegCommands}}
<option value="{{$l.ID}}">{{$l.Name}}</option>
{{end}}
</select>
</form>
<div class="file-list">
<table>
<tr>
<th>ID</th>
<th>Path</th>
<th>Size</th>
<th>Status</th>
<th>Health</th>
<th>Transcode</th>
<th>MD5</th>
<th>Updated At</th>
</tr>
{{range $f := .Files}}
<tr>
<td>
{{ $f.ID }}
</td>
<td>
{{ $f.Path }}
</td>
<td>
{{ $f.Size }}
</td>
<td>
{{ $f.Status }}
</td>
<td>
{{ $f.Health }}
</td>
<td>
{{ $f.Transcode }}
</td>
<td>
{{ $f.MD5 }}
</td>
<td>
{{ $f.UpdatedAt }}
</td>
</tr>
{{end}}
</table>
</div>
{{template "tail"}}