You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
cacert-boardvoting/templates/motions.html

77 lines
2.6 KiB
HTML

<!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="/motions/?unvoted=1">Show my outstanding votes</a><br/>
{{ $voter := .Voter }}
{{ if .Decisions }}
<table class="list">
<thead>
<tr>
<th>Status</th>
<th>Motion</th>
{{ if $voter }}<th>Actions</th>{{ end }}
</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/{{ .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/{{.Tag}}?showvotes=1">Show Votes</a></i>
{{ end }}
</td>
{{ if $voter }}
<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="/motions/{{ .Tag }}/edit">Modify</a></li>
<li><a href="/motions/{{ .Tag }}/withdraw">Withdraw</a></li>
</ul>
{{ end }}
</td>{{ end }}
</tr>
{{end}}
<tr>
<td colspan="{{ if $voter }}3{{ else }}2{{ end }}" class="navigation">
{{ if .PrevPage }}<a href="?page={{ .PrevPage }}" title="previous page">&lt;</a>{{ end }}
{{ if .NextPage }}<a href="?page={{ .NextPage }}" title="next page">&gt;</a>{{ end }}
</td>
</tr>
</tbody>
</table>
{{else}}
<p>There are no motions in the system yet.</p>
{{end}}
</body>
</html>