2020-01-14 18:57:16 +02:00
|
|
|
{{with .Data}}
|
|
|
|
{{template "header.tmpl" (WithContext .HeaderData $.Ctx)}}
|
|
|
|
{{template "navigation.tmpl" (WithContext .NavbarData $.Ctx)}}
|
2019-12-26 21:18:09 +02:00
|
|
|
<div class="page-title"> Search </div>
|
|
|
|
|
|
|
|
<div>
|
|
|
|
<form action="/search" method="GET">
|
|
|
|
<span class="post-form-field>
|
|
|
|
<label for="query"> Query </label>
|
|
|
|
<input id="query" name="q" value="{{.Q}}">
|
|
|
|
</span>
|
|
|
|
<span class="post-form-field>
|
|
|
|
<label for="type"> Type </label>
|
|
|
|
<select id="type" name="type">
|
|
|
|
<option value="statuses" {{if eq .Type "statuses"}}selected{{end}}>Statuses</option>
|
|
|
|
<option value="accounts" {{if eq .Type "accounts"}}selected{{end}}>Accounts</option>
|
|
|
|
</select>
|
|
|
|
</span>
|
|
|
|
<button type="submit"> Search </button>
|
|
|
|
</form>
|
|
|
|
</div>
|
|
|
|
|
|
|
|
{{if eq .Type "statuses"}}
|
|
|
|
{{range .Statuses}}
|
2020-01-14 18:57:16 +02:00
|
|
|
{{template "status.tmpl" (WithContext . $.Ctx)}}
|
2019-12-26 21:18:09 +02:00
|
|
|
{{end}}
|
|
|
|
|
|
|
|
{{end}}
|
|
|
|
{{if eq .Type "accounts"}}
|
2020-01-14 18:57:16 +02:00
|
|
|
{{template "userlist.tmpl" (WithContext .Users $.Ctx)}}
|
2019-12-26 21:18:09 +02:00
|
|
|
{{end}}
|
|
|
|
|
|
|
|
<div class="pagination">
|
2020-01-28 19:51:00 +02:00
|
|
|
{{if .NextLink}}
|
2019-12-26 21:18:09 +02:00
|
|
|
<a href="{{.NextLink}}">next</a>
|
|
|
|
{{end}}
|
|
|
|
</div>
|
2020-01-14 18:57:16 +02:00
|
|
|
|
2019-12-26 21:18:09 +02:00
|
|
|
{{template "footer.tmpl"}}
|
2020-01-14 18:57:16 +02:00
|
|
|
{{end}}
|