Files
Thomas Peetz b3b143cd3f
Gitea Actions Demo / Explore-Gitea-Actions (push) Successful in 7s
parse query parameter
2026-10-22 17:24:13 +02:00

70 lines
3.1 KiB
HTML

{{ define "lofi" }}
<!doctype html>
<html lang="de">
{{ template "head" . }}
<body>
{{ template "navbar" . }}
<main>
<div class="row">
<div class="col-md-8">
<h1>Media Lofi</h1>
<p>Hier steht der wesentliche Inhalt der Seite.</p>
</div>
<div class="col-md-4">
<aside class="bg-light p-3">
<h3>Seitenbereich</h3>
<p>Optionale Sidebar oder Zusatzinformationen.</p>
</aside>
</div>
</div>
<div class="row">
<form class="form-inline" action="/web/media-lofis">
<input type="text" placeholder="Search" name="query">
<label>
<input type="checkbox" name="review" {{if .isReview}}checked{{end}}>Review
</label>
<label>
<input type="checkbox" name="should_download" {{if .isDownload}}checked{{end}}>Download
</label>
<button type="submit">Search</button>
<div class="pill-nav"><a href="/web/media-lofis/add">Add Lofi</a></div>
</form>
</div>
<div class="row">
<table class="table table-hover">
<thead><tr>
<th scope="col">Title</th>
<th scope="col">Weblink</th>
<th scope="col">Review</th>
<th colspan="2">Actions</th>
</tr></thead>
<tbody>
{{ range .lofis }}
<tr>
<th scope="row"><a href="/web/media-lofis/{{.ID}}/edit">{{.Title}}</a></th>
{{ if .WebLink }}
<td><a href="{{.WebLink}}">{{.WebLink}}</a></td>
{{ else }}
<td>WebLink not set</td>
{{ end }}
<td>
{{ if .Review }}
<a href="/web/media-lofis/{{.ID}}/change-review"><img src="/public/icons/tick.png" alt="true" width="24" height="24"></a>
{{ else }}
<a href="/web/media-lofis/{{.ID}}/change-review"><img src="/public/icons/cross.png" alt="true" width="24" height="24"></a>
{{ end }}
</td>
<td><a href="/web/media-lofis/{{.ID}}/edit" class="btn btn-outline-primary btn-sm active" role="button" aria-pressed="true">Edit</a></td>
<td><a href="/web/media-lofis/{{.ID}}/delete" class="btn btn-outline-danger btn-sm active" role="button" aria-pressed="true">Delete</a></td>
</tr>
{{ end }}
</tbody>
</table>
</div>
</main>
{{ template "footer" . }}
</body>
</html>
{{ end }}