cacert-boardvoting/boardvoting/templates/motions.html

52 lines
2.2 KiB
HTML
Raw Normal View History

{{ template "header.html" . }}
{{ $voter := .Voter }}
2017-04-29 20:17:58 +00:00
<div class="column">
2017-04-30 00:37:29 +00:00
<div class="ui basic segment">
<div class="ui floated right secondary menu">
<a href="/motions/" class="{{ if not .Params.Flags.Unvoted }}active {{ end }}item" title="Show all votes">All votes</a>
{{ 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 }}
</div>
{{ if $voter }}<a class="ui primary button" href="/newmotion/">New motion</a>{{ end }}
{{ if .PrevPage -}}
<a href="?page={{ .PrevPage }}{{ if .Params.Flags.Unvoted }}&unvoted=1{{ end }}"
class="ui left labeled icon button" title="newer motions"><i class="left arrow icon"></i> newer</a>
{{- end }}
{{ if .NextPage -}}
<a href="?page={{ .NextPage }}{{ if .Params.Flags.Unvoted }}&unvoted=1{{ end }}"
class="ui right labeled icon button" title="older motions"><i class="right arrow icon"></i> older</a>
{{- end }}
2017-04-29 20:17:58 +00:00
</div>
</div>
2017-04-15 17:23:40 +00:00
{{ if .Decisions }}
2017-04-29 20:17:58 +00:00
{{ range .Decisions }}
2017-04-30 00:37:29 +00:00
<div class="column">
<div class="ui raised segment">
{{ template "motion_fragment" . }}
{{ if $voter }}{{ template "motion_actions" . }}{{ end }}
2017-04-30 00:37:29 +00:00
</div>
</div>
{{ end }}
<div class="column">
<div class="ui basic segment">
{{ if $voter }}<a class="ui primary button" href="/newmotion/">New motion</a>{{ end }}
{{ if .PrevPage -}}
<a href="?page={{ .PrevPage }}{{ if .Params.Flags.Unvoted }}&unvoted=1{{ end }}"
class="ui left labeled icon button" title="newer motions">
<i class="left arrow icon"></i> newer</a>
{{- end }}
{{ if .NextPage -}}
<a href="?page={{ .NextPage }}{{ if .Params.Flags.Unvoted }}&unvoted=1{{ end }}"
class="ui right labeled icon button" title="older motions">
<i class="right arrow icon"></i> older</a>
{{- end }}
</div>
</div>
{{ else }}
2017-04-30 00:37:29 +00:00
{{ if .Params.Flags.Unvoted }}
<p>There are no motions requiring a vote from you.</p>
{{ else }}
<p>There are no motions in the system yet.</p>
{{ end }}
{{ end }}
{{ template "footer.html" . }}