List tx templates on homepage

This commit is contained in:
Wancat
2022-10-18 03:04:33 +08:00
parent 7c50e3fc5c
commit 482c293dec
2 changed files with 9 additions and 3 deletions

20
templates/index.html Normal file
View File

@@ -0,0 +1,20 @@
<!DOCTYPE html>
<html>
<head>
<title>Ledger Quick Note</title>
</head>
<body>
<h1>Ledger Quick Note</h1>
<form action="/action" method="POST">
<label>Action: <select name="action">
{{ range .Templates }}
{{ if ne .Name "index.html" }}
<option value="{{ .Name }}">{{ .Name }}</option>
{{ end }}
{{ end }}
</select></label>
<label>Amount: <input name="amount" type="number"></label>
<input type="submit">
</form>
</body>
</html>