Initial Go code for reimplementation
[cacert-boardvoting.git] / templates / motions.html
1 <!DOCTYPE html>
2 <html xmlns="http://www.w3.org/1999/html">
3 <head>
4 <title>CAcert Board Decisions</title>
5 <meta http-equiv="Content-Type" content="text/html; charset=utf-8"/>
6 <link rel="stylesheet" type="text/css" href="/static/styles.css"/>
7 </head>
8 <body>
9 <a href="?unvoted=1">Show my outstanding votes</a><br/>
10 {{ if .Decisions }}
11 <table class="list">
12 <thead>
13 <tr>
14 <th>Status</th>
15 <th>Motion</th>
16 <th>Actions</th>
17 </tr>
18 </thead>
19 <tbody>
20 {{range .Decisions }}
21 <tr>
22 <td class="{{.Status}}">
23 {{ if eq .Status 0 }}Pending {{ .Due}}
24 {{ else if eq .Status 1}}Approved {{ .Modified}}
25 {{ else if eq .Status -1}}Declined {{ .Modified}}
26 {{ else if eq .Status -2}}Withdrawn {{ .Modified}}
27 {{ else }}Unknown
28 {{ end }}
29 </td>
30 <td>
31 <i><a href="/motions?motion={{ .Tag}}">{{ .Tag}}</a></i><br />
32 <b>{{ .Title}}</b><br />
33 <pre>{{ wrap 76 .Content }}</pre>
34 <br />
35 <i>Due: {{.Due}}</i><br/>
36 <i>Proposed: {{.Proposer}} ({{.Proposed}})</i><br/>
37 <i>Vote type: {{.VoteType}}</i><br/>
38 <i>Aye|Naye|Abstain: {{.Ayes}}|{{.Nayes}}|{{.Abstains}}</i><br />
39 {{ if .Votes }}
40 <i>Votes:</i><br/>
41 {{ range .Votes}}
42 <i>{{ .Name }}: {{ .Vote}}</i><br />
43 {{ end }}
44 {{ else}}
45 <i><a href="/motions?motion={{.Tag}}&showvotes=1">Show Votes</a></i>
46 {{ end }}
47 </td>
48 <td>
49 {{ if eq .Status 0 }}
50 <ul>
51 <li><a href="/vote/{{ .Tag }}/aye">Aye</a></li>
52 <li><a href="/vote/{{ .Tag }}/abstain">Abstain</a></li>
53 <li><a href="/vote/{{ .Tag }}/naye">Naye</a></li>
54 <li><a href="/proxy/{{ .Tag }}">Proxy Vote</a></li>
55 <li><a href="/motion/{{ .Tag }}">Modify</a></li>
56 <li><a href="/motions?motion={{ .Tag }}&withdraw=1">Withdraw</a></li>
57 </ul>
58 {{ end }}
59 </td>
60 </tr>
61 {{end}}
62 </tbody>
63 </table>
64 {{else}}
65 <p>There are no motions in the system yet.</p>
66 {{end}}
67 </body>
68 </html>