DEVELOPMENT ENVIRONMENT

~liljamo/felu

ref: 718ba8a948df3e8990e393575be4c667c339e459 felu/internal/components/adminpartials.templ -rw-r--r-- 724 bytes
718ba8a9Jonni Liljamo feat: don't allow full stops in domains 11 months ago
                                                                                
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
package components

import "git.src.quest/~skye/felu-ddns/internal/db"
import "strconv"

templ AdminPartialUsersList(users []db.User) {
	<table class="table-auto">
		<thead>
			<tr>
				<th class="text-start p-2">
					Id
				</th>
				<th class="text-start p-2">
					Email
				</th>
				<th class="text-start p-2">
					Is Admin
				</th>
			</tr>
		</thead>
		<tbody>
			for _, user := range users {
				<tr class="border">
					<td>
						<div class="p-2">
							{ user.Id }
						</div>
					</td>
					<td>
						<div class="p-2">
							{ user.Email }
						</div>
					</td>
					<td>
						<div class="p-2">
							{ strconv.FormatBool(user.IsAdmin) }
						</div>
					</td>
				</tr>
			}
		</tbody>
	</table>
}