udemy-go-web-2/cmd/web/templates/all-sales.page.gohtml

27 lines
542 B
Plaintext
Raw Normal View History

2024-08-21 21:18:51 +00:00
{{ template "base" . }}
{{ define "title" }}
2024-08-21 19:49:08 +00:00
All Subscriptions
2024-08-21 21:18:51 +00:00
{{ end }}
{{ define "content" }}
2024-08-21 19:49:08 +00:00
<h2 class="mt-5">All Sales</h2>
<hr>
2024-08-21 21:18:51 +00:00
<table id="sales-table" class="table table-striped">
<thead>
<tr>
<th>Transaction</th>
<th>Customer</th>
<th>Product</th>
<th>Amount</th>
</tr>
</thead>
<tbody>
</tbody>
</table>
{{ end }}
{{ define "js" }}
<script type="module">
import {showTable} from "/static/js/all-sales.js"
showTable({{.API}});
</script>
{{ end }}