2026-06-19 02:04:42 +00:00
|
|
|
{{define "title"}}{{.Title}}{{end}}
|
|
|
|
|
{{define "content"}}
|
|
|
|
|
<header>
|
|
|
|
|
<span><a href="/">← Add receipt</a></span>
|
|
|
|
|
<span><a href="/tally">Tally</a> · <a href="/manage">Manage</a> · <a href="/export">Export</a></span>
|
|
|
|
|
</header>
|
|
|
|
|
<h1>{{.Title}}</h1>
|
|
|
|
|
<p class="tabs">
|
|
|
|
|
<a href="/recent"{{if eq .BasePath "/recent"}} class="active"{{end}}>By upload date</a> ·
|
|
|
|
|
<a href="/recent/receipts"{{if eq .BasePath "/recent/receipts"}} class="active"{{end}}>By receipt date</a>
|
|
|
|
|
</p>
|
|
|
|
|
{{if not .Rows}}
|
|
|
|
|
<p><small>No receipts to show.</small></p>
|
|
|
|
|
{{else}}
|
|
|
|
|
<ul class="recent">
|
|
|
|
|
{{range .Rows}}
|
|
|
|
|
<li>
|
|
|
|
|
<a href="/receipt/{{.ID}}/file" target="_blank">${{.Amount}}</a>
|
|
|
|
|
· {{.Date}} · {{.Category}}{{if .Who}} · {{.Who}}{{end}}
|
|
|
|
|
<br><small>{{.Filename}} — uploaded {{.When}}</small>
|
2026-06-19 11:06:15 +00:00
|
|
|
{{if .Attachments}}<br><small>attachments: {{range $i, $a := .Attachments}}{{if $i}}, {{end}}<a href="/attachment/{{$a.ID}}/file" target="_blank">{{$a.Filename}}</a>{{end}}</small>{{end}}
|
2026-06-19 02:04:42 +00:00
|
|
|
</li>
|
|
|
|
|
{{end}}
|
|
|
|
|
</ul>
|
|
|
|
|
<p class="pager">
|
|
|
|
|
{{if .PrevURL}}<a href="{{.PrevURL}}">← Newer</a>{{end}}
|
|
|
|
|
{{if and .PrevURL .NextURL}} · {{end}}
|
|
|
|
|
{{if .NextURL}}<a href="{{.NextURL}}">Load next 10 →</a>{{end}}
|
|
|
|
|
</p>
|
|
|
|
|
{{end}}
|
|
|
|
|
{{end}}
|