forked from adamlaska/datatracker
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathdocument_ballot_content.html
More file actions
237 lines (237 loc) · 13 KB
/
document_ballot_content.html
File metadata and controls
237 lines (237 loc) · 13 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
{# Copyright The IETF Trust 2015, All Rights Reserved #}
{% load origin %}
{% origin %}
{% load ietf_filters %}
{% load textfilters %}
<div class="row">
<div class="col-md-2 d-none d-md-block d-sm-block d-lg-block d-xl-block d-xxl-block">
{% for n, positions in position_groups %}
<h5>
<span class="badge {{ n|pos_to_label_format }}">{{ n.name }}</span>
</h5>
{% for p in positions %}
<div class="balloter-name mb-2">
{% if p.is_old_pos %}
<span class="text-muted">
(
{% endif %}
{% if p.comment or p.discuss %}<a href="#{{ doc.name|slugify }}_{{ p.balloter.plain_name|slugify }}">{% endif %}
{{ p.balloter.plain_name }}
{% if p.comment or p.discuss %}</a>{% endif %}
{% if p.is_old_pos %}
)
</span>
{% endif %}
</div>
{% empty %}
<span class="text-muted">(None)</span>
{% endfor %}
<br>
{% endfor %}
</div>
<div class="col-md-10">
{% if all_ballots and all_ballots|length > 1 %}
<ul class="pagination pagination-sm">
<li class="disabled">
<span>
<b>Ballots</b>
</span>
</li>
{% for b in all_ballots %}
<li {% if b == ballot %}class="active"{% endif %}>
<a href="{% url "ietf.doc.views_doc.document_ballot" name=doc.name ballot_id=b.pk %}">
{{ b.ballot_type.name }} ({{ b.rev }})
</a>
</li>
{% endfor %}
</ul>
{% endif %}
{% if doc.type_id == "draft" or doc.type_id == "conflrev" or doc.type_id == "statchg" %}
{% if deferred %}
<p class="alert alert-danger my-3">
Ballot deferred by {{ deferred.by }} on {{ deferred.time|date:"Y-m-d" }}.
</p>
{% endif %}
{% endif %}
{% if not ballot_open %}
<p class="alert alert-warning my-3">
<b>Note:</b> This ballot was opened for revision {{ ballot.rev }} and is now closed.
</p>
{% else %}
<p class="alert alert-info my-3">
<b>Summary:</b> {{ summary }}
</p>
{% endif %}
{% if ballot.ballot_type.question %}
<p class="alert alert-secondary my-3">
<b>Ballot question:</b> "{{ ballot.ballot_type.question }}"
</p>
{% endif %}
{% if editable and user|has_role:"Area Director,Secretariat,IRSG Member" %}
<a class="btn btn-primary my-3"
href="https://mailarchive.ietf.org/arch/search/?q=subject:{{ doc.name }}+AND+subject:(discuss+OR+comment+OR+review)">
Search Mailarchive
</a>
{% if user|can_ballot:doc %}
<a class="btn btn-primary"
href="{% url "ietf.doc.views_ballot.edit_position" name=doc.name ballot_id=ballot.pk %}">
Edit position
</a>
{% endif %}
{% if doc.type_id == "draft" or doc.type_id == "conflrev" or doc.type_id == "statchg" %}
{% if deferred %}
<a class="btn btn-warning"
href="{% url 'ietf.doc.views_ballot.undefer_ballot' name=doc.name %}">Undefer ballot</a>
{% else %}
{% if doc.telechat_date %}
<a class="btn btn-warning"
href="{% url 'ietf.doc.views_ballot.defer_ballot' name=doc.name %}">Defer ballot</a>
{% endif %}
{% endif %}
{% if user|has_role:"Area Director,Secretariat" and ballot.ballot_type.slug != "irsg-approve" %}
<a class="btn btn-danger"
href="{% url 'ietf.doc.views_ballot.clear_ballot' name=doc.name ballot_type_slug=ballot.ballot_type.slug %}">
Clear ballot
</a>
{% endif %}
{% endif %}
{% endif %}
{% for n, positions in position_groups %}
{% for p in positions %}
{% if not p.is_old_pos %}
<h5 class="mt-4"
id="{{ doc.name|slugify }}_{{ p.balloter.plain_name|slugify }}">
{{ p.balloter.plain_name }}
<span class="float-end">
{% if p.old_positions %}<span class="text-muted small">(was {{ p.old_positions|join:", " }})</span>{% endif %}
<span class="badge {{ p.pos|pos_to_label_format }}">{{ p.pos }}</span>
{% if user|has_role:"Secretariat" %}
<a href="{% url "ietf.doc.views_ballot.edit_position" name=doc.name ballot_id=ballot.pk %}?balloter={{ p.balloter.pk }}"
title="Click to edit the position of {{ p.balloter.plain_name }}"
class="btn btn-primary btn-sm">
Edit
</a>
{% endif %}
</span>
</h5>
{% if p.pos.blocking and p.discuss %}
<div class="card border-danger {% if p.comment %} mb-2{% endif %}">
<div class="card-header bg-danger text-light">
<div>
<b>{{ p.pos.name }}</b> ({{ p.discuss_time|date:"Y-m-d" }}
{% if not p.for_current_revision %}for -{{ p.get_dochistory.rev }}{% endif %}
)
{% if p.send_email %}
<i class="bi bi-envelope float-end"
title="Email requested to be sent for this discuss"></i>
{% elif p.any_email_sent == True %}
<i class="bi bi-envelope float-end"
title="Email requested to be sent for earlier discuss"></i>
{% elif p.any_email_sent == False %}
<i class="bi bi-chat-o float-end"
title="No email send requests for this discuss"></i>
{% else %}
<i class="bi bi-chat-o float-end"
title="No email send requests for this discuss"></i>
{% endif %}
</div>
</div>
<div class="card-body">
<pre class="ballot pasted">{{ p.discuss|linkify|urlize_ietf_docs }}</pre>
</div>
</div>
{% endif %}
{% if p.comment %}
<div class="card {{ p.pos|pos_to_border_format }}">
<div class="card-header {{ p.pos|pos_to_label_format }}">
<div>
<b>Comment</b> ({{ p.comment_time|date:"Y-m-d" }}
{% if not p.for_current_revision %}for -{{ p.get_dochistory.rev }}{% endif %}
)
{% if p.send_email %}
<i class="bi bi-envelope-check float-end"
title="Email requested to be sent for this comment"></i>
{% elif p.any_email_sent == True %}
<i class="bi bi-envelope-plus float-end"
title="Email requested to be sent for earlier comment"></i>
{% elif p.any_email_sent == False %}
<i class="bi bi-envelope-dash float-end"
title="No email send requests for this comment"></i>
{% else %}
<i class="bi bi-envelope-exclamation float-end"
title="No ballot position send log available"></i>
{% endif %}
</div>
</div>
<div class="card-body">
<pre class="ballot pasted">{{ p.comment|linkify|urlize_ietf_docs }}</pre>
</div>
</div>
{% endif %}
{% endif %}
{% endfor %}
{% endfor %}
{% for n, positions in position_groups %}
{% for p in positions %}
{% if p.is_old_pos %}
<h5 id="{{ doc.name|slugify }}_{{ p.balloter.plain_name|slugify }}">
<span class="text-muted">({{ p.balloter.plain_name }}; former steering group member)</span>
<span class="float-end">
{% if p.old_positions %}<span class="text-muted small">(was {{ p.old_positions|join:", " }})</span>{% endif %}
<span class="badge {{ p.pos|pos_to_label_format }}">{{ p.pos }}</span>
{% if user|has_role:"Secretariat" %}
<a href="{% url "ietf.doc.views_ballot.edit_position" name=doc.name ballot_id=ballot.pk %}?balloter={{ p.balloter.pk }}"
title="Click to edit the position of {{ p.balloter.plain_name }}"
class="btn btn-primary btn-sm">
Edit
</a>
{% endif %}
</span>
</h5>
<div class="card {{ p.pos|pos_to_border_format }}">
<div class="card-header {{ p.pos|pos_to_label_format }}">
<div>
<b>{{ p.pos.name }} </b>
{% if p.pos.blocking and p.discuss %}
<b>[Treat as non-blocking comment]</b> ({{ p.discuss_time|date:"Y-m-d" }}
{% if not p.for_current_revision %}for -{{ p.get_dochistory.rev }}{% endif %}
)
{% else %}
({{ p.comment_time|date:"Y-m-d" }}
{% if not p.for_current_revision %}for -{{ p.get_dochistory.rev }}{% endif %}
)
{% endif %}
{% if p.send_email %}
<i class="bi bi-envelope float-end"
title="Email requested to be sent for this ballot position"></i>
{% elif p.any_email_sent == True %}
<i class="bi bi-envelope float-end"
title="Email requested to be sent for earlier ballot position"></i>
{% elif p.any_email_sent == False %}
<i class="bi bi-chat-o float-end"
title="No email send requests for this ballot position"></i>
{% else %}
<div class="float-end small italic"
title="No ballot position send log available">
No email
<br>
send info
</div>
{% endif %}
</div>
</div>
{% if p.pos.blocking and p.discuss %}
<div class="card-body">
<pre class="ballot pasted">{{ p.discuss|linkify|urlize_ietf_docs }}</pre>
</div>
{% else %}
<div class="card-body">
<pre class="ballot pasted">{{ p.comment|linkify|urlize_ietf_docs }}</pre>
</div>
{% endif %}
</div>
{% endif %}
{% endfor %}
{% endfor %}
</div>
</div>