about summary refs log tree commit diff
path: root/templates/bots.html
blob: 70018dd7f7e13285b5b9a093c2edda506c64e85b (plain)
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
{{ define "bots" }}

{{ template "head" . }}
<body>
  {{ template "nav" . }}

  <span id="allbots"></span>
  <h1><a href="#allbots">All Bots</a></h1>

  <table>
    <tr>
      <td>Bot</td>
      <td>User</td>
    <tr>
  {{ range $bot := .bots }}
    <tr>
      <td>
        <a href="/bot/{{ $bot.ID }}">{{ $bot.Name }}</a>
      </td>
      <td>
        {{ range $idx, $usr := $bot.Users }}{{if $idx}},{{end}}<a href="/user/{{ $usr.ID }}">{{ $usr.Name }}</a>{{ end }}
      </td>
    </tr>
  {{ end }}
  </table>
</body>
{{ template "footer" . }}
{{ end }}