summaryrefslogtreecommitdiff
path: root/templates/motions.html
diff options
context:
space:
mode:
authorJan Dittberner <jandd@cacert.org>2017-04-15 19:23:40 +0200
committerJan Dittberner <jandd@cacert.org>2017-04-15 19:23:40 +0200
commit74987ce184fb3c4ddc3d266aa19f7fcacd774bf0 (patch)
treeebd3ec1d3e4ceb63e2ea485512c68adee5760e6b /templates/motions.html
parent37c6f2efe60807b23d336f00a740acf7941757a4 (diff)
downloadcacert-boardvoting-74987ce184fb3c4ddc3d266aa19f7fcacd774bf0.tar.gz
cacert-boardvoting-74987ce184fb3c4ddc3d266aa19f7fcacd774bf0.tar.xz
cacert-boardvoting-74987ce184fb3c4ddc3d266aa19f7fcacd774bf0.zip
Initial Go code for reimplementation
Diffstat (limited to 'templates/motions.html')
-rw-r--r--templates/motions.html68
1 files changed, 68 insertions, 0 deletions
diff --git a/templates/motions.html b/templates/motions.html
new file mode 100644
index 0000000..fa1c07c
--- /dev/null
+++ b/templates/motions.html
@@ -0,0 +1,68 @@
+<!DOCTYPE html>
+<html xmlns="http://www.w3.org/1999/html">
+<head>
+ <title>CAcert Board Decisions</title>
+ <meta http-equiv="Content-Type" content="text/html; charset=utf-8"/>
+ <link rel="stylesheet" type="text/css" href="/static/styles.css"/>
+</head>
+<body>
+<a href="?unvoted=1">Show my outstanding votes</a><br/>
+{{ if .Decisions }}
+<table class="list">
+ <thead>
+ <tr>
+ <th>Status</th>
+ <th>Motion</th>
+ <th>Actions</th>
+ </tr>
+ </thead>
+ <tbody>
+ {{range .Decisions }}
+ <tr>
+ <td class="{{.Status}}">
+ {{ if eq .Status 0 }}Pending {{ .Due}}
+ {{ else if eq .Status 1}}Approved {{ .Modified}}
+ {{ else if eq .Status -1}}Declined {{ .Modified}}
+ {{ else if eq .Status -2}}Withdrawn {{ .Modified}}
+ {{ else }}Unknown
+ {{ end }}
+ </td>
+ <td>
+ <i><a href="/motions?motion={{ .Tag}}">{{ .Tag}}</a></i><br />
+ <b>{{ .Title}}</b><br />
+ <pre>{{ wrap 76 .Content }}</pre>
+ <br />
+ <i>Due: {{.Due}}</i><br/>
+ <i>Proposed: {{.Proposer}} ({{.Proposed}})</i><br/>
+ <i>Vote type: {{.VoteType}}</i><br/>
+ <i>Aye|Naye|Abstain: {{.Ayes}}|{{.Nayes}}|{{.Abstains}}</i><br />
+ {{ if .Votes }}
+ <i>Votes:</i><br/>
+ {{ range .Votes}}
+ <i>{{ .Name }}: {{ .Vote}}</i><br />
+ {{ end }}
+ {{ else}}
+ <i><a href="/motions?motion={{.Tag}}&showvotes=1">Show Votes</a></i>
+ {{ end }}
+ </td>
+ <td>
+ {{ if eq .Status 0 }}
+ <ul>
+ <li><a href="/vote/{{ .Tag }}/aye">Aye</a></li>
+ <li><a href="/vote/{{ .Tag }}/abstain">Abstain</a></li>
+ <li><a href="/vote/{{ .Tag }}/naye">Naye</a></li>
+ <li><a href="/proxy/{{ .Tag }}">Proxy Vote</a></li>
+ <li><a href="/motion/{{ .Tag }}">Modify</a></li>
+ <li><a href="/motions?motion={{ .Tag }}&withdraw=1">Withdraw</a></li>
+ </ul>
+ {{ end }}
+ </td>
+ </tr>
+ {{end}}
+ </tbody>
+</table>
+{{else}}
+<p>There are no motions in the system yet.</p>
+{{end}}
+</body>
+</html> \ No newline at end of file