update index
This commit is contained in:
@@ -1,29 +1,25 @@
|
|||||||
{{ define "index" }}
|
{{ define "index" }}
|
||||||
<a href="/new">+ Add New Draw</a>
|
<a href="/new">+ Add New Draw</a>
|
||||||
|
|
||||||
{{ if . }}
|
|
||||||
<table>
|
<table>
|
||||||
<tr>
|
<tr>
|
||||||
<th>Date</th>
|
<th>Date</th>
|
||||||
<th>Numbers</th>
|
<th>Machine</th>
|
||||||
<th>Spend (£)</th>
|
<th>Ball Set</th>
|
||||||
<th>Return (£)</th>
|
<th>Balls</th>
|
||||||
<th>Profit/Loss (£)</th>
|
<th>Thunderball</th>
|
||||||
</tr>
|
</tr>
|
||||||
|
{{ if . }}
|
||||||
{{ range . }}
|
{{ range . }}
|
||||||
<tr>
|
<tr>
|
||||||
<td>{{ .Date }}</td>
|
<td>{{ .Date }}</td>
|
||||||
<td>{{ .Numbers }}</td>
|
<td>{{ .Machine }}</td>
|
||||||
<td>{{ printf "%.2f" .Spend }}</td>
|
<td>{{ .Ballset }}</td>
|
||||||
<td>{{ printf "%.2f" .Return }}</td>
|
<td>{{ .Ball1 }}, {{ .Ball2 }}, {{ .Ball3 }}, {{ .Ball4 }}, {{ .Ball5 }}</td>
|
||||||
<td>{{ printf "%.2f" .ProfitLoss }}</td>
|
<td>{{ .Thunderball }}</td>
|
||||||
</tr>
|
</tr>
|
||||||
|
{{ end }}
|
||||||
{{ else }}
|
{{ else }}
|
||||||
<tr><td colspan="5">No draws recorded yet.</td></tr>
|
<tr><td colspan="5">No draws recorded yet.</td></tr>
|
||||||
{{ end }}
|
{{ end }}
|
||||||
</table>
|
</table>
|
||||||
{{ else }}
|
|
||||||
<p>No draws recorded yet. <a href="/new">Add your first draw</a></p>
|
|
||||||
{{ end }}
|
|
||||||
|
|
||||||
{{ end }}
|
{{ end }}
|
||||||
|
|||||||
Reference in New Issue
Block a user