I can now list the contents of a table and display a form for one row to update/delete, but haven't implemented update and delete.
This commit is contained in:
parent
2b40d6fdc3
commit
d12817f4cc
4 changed files with 49 additions and 17 deletions
|
@ -7,14 +7,24 @@
|
|||
<h1>Admin Tables</h1>
|
||||
|
||||
<block x-data="Tables">
|
||||
<ul>
|
||||
<table>
|
||||
<template x-for="item in theData">
|
||||
<table>
|
||||
<td><a x-bind:href="'/admin/table/{{ .Table }}/' + item.id + '/'" x-text="item.id"></td>
|
||||
<td x-text="item.Email"></td>
|
||||
</table>
|
||||
<tr>
|
||||
<td>
|
||||
<a x-bind:href="'/admin/table/{{ .Table }}/' + item.id + '/'">
|
||||
^
|
||||
</a>
|
||||
</td>
|
||||
<template x-for="(value, key) in item">
|
||||
<td x-text="value"></td>
|
||||
</template>
|
||||
</tr>
|
||||
</template>
|
||||
</ul>
|
||||
</table>
|
||||
<block class="horizontal">
|
||||
<a href="/admin/table/{{.Table}}/?page=2">Prev</a>
|
||||
<a href="/admin/table/{{.Table}}/?page=2">Next</a>
|
||||
</block>
|
||||
</block>
|
||||
|
||||
</blockstart>
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue