3f820924e14620bd6cdc7860bd96419e185c57f1
[cacert-boardvoting.git] / boardvoting / templates / motions.html
1 {{ template "header" . }}
2 {{ $voter := .Voter }}
3 <div class="column">
4 <div class="ui basic segment">
5 <div class="ui floated right secondary menu">
6
7 <a href="/motions/" class="{{ if not .Params.Flags.Unvoted }}active {{ end }}item" title="Show all votes">All votes</a>
8 {{ if $voter }}<a href="/motions/?unvoted=1" class="{{ if .Params.Flags.Unvoted }}active {{ end}}item" title="Show my outstanding votes">My outstanding votes</a>{{ end }}
9 </div>
10 {{ if $voter }}<a class="ui primary button" href="/newmotion/">New motion</a>{{ end }}
11 {{ if .PrevPage -}}
12 <a href="?page={{ .PrevPage }}{{ if .Params.Flags.Unvoted }}&unvoted=1{{ end }}"
13 class="ui left labeled icon button" title="newer motions"><i class="left arrow icon"></i> newer</a>
14 {{- end }}
15 {{ if .NextPage -}}
16 <a href="?page={{ .NextPage }}{{ if .Params.Flags.Unvoted }}&unvoted=1{{ end }}"
17 class="ui right labeled icon button" title="older motions"><i class="right arrow icon"></i> older</a>
18 {{- end }}
19 </div>
20 </div>
21 {{ if .Decisions }}
22 {{ range .Decisions }}
23 <div class="column">
24 <div class="ui raised segment">
25 {{ template "motion_fragment" . }}
26 {{ if $voter }}{{ template "motion_actions" . }}{{ end }}
27 </div>
28 </div>
29 {{ end }}
30 <div class="column">
31 <div class="ui basic segment">
32 {{ if $voter }}<a class="ui primary button" href="/newmotion/">New motion</a>{{ end }}
33 {{ if .PrevPage -}}
34 <a href="?page={{ .PrevPage }}{{ if .Params.Flags.Unvoted }}&unvoted=1{{ end }}"
35 class="ui left labeled icon button" title="newer motions">
36 <i class="left arrow icon"></i> newer</a>
37 {{- end }}
38 {{ if .NextPage -}}
39 <a href="?page={{ .NextPage }}{{ if .Params.Flags.Unvoted }}&unvoted=1{{ end }}"
40 class="ui right labeled icon button" title="older motions">
41 <i class="right arrow icon"></i> older</a>
42 {{- end }}
43 </div>
44 </div>
45 {{ else }}
46 {{ if .Params.Flags.Unvoted }}
47 <p>There are no motions requiring a vote from you.</p>
48 {{ else }}
49 <p>There are no motions in the system yet.</p>
50 {{ end }}
51 {{ end }}
52 {{ template "footer" . }}