This gets almost everything done, including Paging, but not search.

This commit is contained in:
Zed A. Shaw 2025-07-28 02:16:59 -04:00
parent da183c453c
commit 51b18823ae
7 changed files with 64 additions and 65 deletions

View file

@ -1,17 +1,20 @@
<script>
let Data = new PaginateTable("/api/admin/table/")
</script>
<blockstart>
<h1>Admin Rows</h1>
<h1>{{ .TableName }} </h1>
<block>
<table>
<tr><th>ID</th></tr>
{{ range $index, $row := .Table }}
<tr>
<td>{{ $row }}</td>
</tr>
{{ end }}
</table>
<block x-data="Data">
<ul>
<template x-for="item in contents">
<li>
<a x-bind:href="`/admin/table/${item}`">
<span x-text="item"></span>
</a>
</li>
</template>
</ul>
</block>
</blockstart>