Skip to content

Commit 1d6cca7

Browse files
committed
Merged in changes from rjsparks@nostrum.com, changeset [3107]. Fixes issues ietf-tools#659, ietf-tools#660, ietf-tools#661, ietf-tools#662 and ietf-tools#663.
- Legacy-Id: 3109 Note: SVN reference [3107] has been migrated to Git commit 6484874
2 parents ccf0463 + 6484874 commit 1d6cca7

8 files changed

Lines changed: 60 additions & 26 deletions

File tree

ietf/idrfc/views_ballot.py

Lines changed: 17 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -59,6 +59,13 @@ class EditPositionForm(forms.Form):
5959
discuss_text = forms.CharField(required=False, widget=forms.Textarea)
6060
comment_text = forms.CharField(required=False, widget=forms.Textarea)
6161
return_to_url = forms.CharField(required=False, widget=forms.HiddenInput)
62+
def clean_discuss_text(self):
63+
entered_discuss = self.cleaned_data["discuss_text"]
64+
entered_pos = self.cleaned_data["position"]
65+
if entered_pos == "discuss" and not entered_discuss:
66+
print "Raising discuss ",entered_pos," ",entered_discuss
67+
raise forms.ValidationError("You must enter a non-empty discuss")
68+
return entered_discuss
6269

6370
@group_required('Area_Director','Secretariat')
6471
def edit_position(request, name):
@@ -164,7 +171,13 @@ def edit_position(request, name):
164171
qstr += "&ad=%s" % request.GET.get('ad')
165172
return HttpResponseRedirect(urlreverse("doc_send_ballot_comment", kwargs=dict(name=doc.filename)) + qstr)
166173
else:
167-
return HttpResponseRedirect(return_to_url)
174+
if request.POST.get("Defer"):
175+
return HttpResponseRedirect(urlreverse("doc_defer_ballot", kwargs=dict(name=doc)))
176+
else:
177+
if request.POST.get("Undefer"):
178+
return HttpResponseRedirect(urlreverse("doc_undefer_ballot", kwargs=dict(name=doc)))
179+
else:
180+
return HttpResponseRedirect(return_to_url)
168181
else:
169182
initial = {}
170183
if pos:
@@ -307,12 +320,14 @@ def undefer_ballot(request, name):
307320
raise Http404()
308321

309322
login = IESGLogin.objects.get(login_name=request.user.username)
323+
telechat_date = TelechatDates.objects.all()[0].date1
310324

311325
if request.method == 'POST':
312326
doc.idinternal.ballot.defer = False
313327
doc.idinternal.ballot.save()
314328

315329
doc.idinternal.change_state(IDState.objects.get(document_state_id=IDState.IESG_EVALUATION), None)
330+
doc.idinternal.telechat_date = telechat_date
316331
doc.idinternal.event_date = date.today()
317332
doc.idinternal.save()
318333

@@ -321,7 +336,7 @@ def undefer_ballot(request, name):
321336
return HttpResponseRedirect(doc.idinternal.get_absolute_url())
322337

323338
return render_to_response('idrfc/undefer_ballot.html',
324-
dict(doc=doc),
339+
dict(doc=doc,telechat_date=telechat_date),
325340
context_instance=RequestContext(request))
326341

327342
class LastCallTextForm(forms.ModelForm):

ietf/idtracker/admin.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,8 @@ class ChairsHistoryAdmin(admin.ModelAdmin):
3131
admin.site.register(ChairsHistory, ChairsHistoryAdmin)
3232

3333
class DocumentCommentAdmin(admin.ModelAdmin):
34-
list_display=('document', 'date', 'time', 'comment_text')
34+
ordering=['-date']
35+
list_display=('pk', 'doc_id', 'date', 'time', 'comment_text')
3536
admin.site.register(DocumentComment, DocumentCommentAdmin)
3637

3738
class EmailAddressAdmin(admin.ModelAdmin):

ietf/idtracker/models.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -690,6 +690,8 @@ def datetime(self):
690690
# this is just a straightforward combination, except that the time is
691691
# stored incorrectly in the database.
692692
return datetime.datetime.combine( self.date, datetime.time( * [int(s) for s in self.time.split(":")] ) )
693+
def doc_id(self):
694+
return self.document_id
693695
class Meta:
694696
db_table = 'document_comments'
695697

ietf/templates/idrfc/doc_tab_document.html

Lines changed: 0 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -65,16 +65,6 @@
6565
{% endif %}
6666
{% endifequal %}
6767

68-
{# links to old system #}
69-
<span id="doc_edit_button" class="yui-button yui-link-button" style="margin-left:2px;"><span class="first-child">
70-
{% if doc.in_ietf_process %}
71-
<a href="https://datatracker.ietf.org/cgi-bin/idtracker.cgi?command=view_id&amp;{% if info.is_rfc %}dTag={{doc.rfc_number}}&amp;rfc_flag=1{% else %}dTag={{doc.tracker_id}}{% endif %}" rel="nofollow" target="_blank">Edit (old IESG Tracker)</a>
72-
{% else %}
73-
<a href="https://datatracker.ietf.org/cgi-bin/idtracker.cgi?command=add_id_confirm&amp;{% if info.is_rfc %}dTag={{doc.rfc_number}}&amp;rfc_flag=1{% else %}dTag={{doc.tracker_id}}&amp;rfc_flag=0{% endif %}&amp;ballot_id=0" rel="nofollow" target="_blank">Add (old IESG Tracker)</a>
74-
{% endif %}
75-
</span></span>
76-
{# end links to old #}
77-
7868
</div>
7969
{% endif %}{# if user in group #}
8070
{% endblock doc_metabuttons%}

ietf/templates/idrfc/edit_position.html

Lines changed: 14 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -31,26 +31,29 @@
3131
{% block content %}
3232
<h1>Change position for {{ ad }} on {{ doc }}</h1>
3333

34-
<form class="position-form" action="" method="POST">
35-
36-
<div>
37-
<div class="position">{{ form.position }}</div>
38-
3934
{% if ballot.was_deferred %}
40-
<div style="margin-top:8px; margin-bottom:8px;"><span id="doc_undefer_ballot_button" class="yui-button yui-link-button"><span class="first-child"><a href="{% url doc_undefer_ballot name=doc %}">Undefer ballot</a></span></span></div>
4135
<div style="margin-top:8px; margin-bottom:8px;">Ballot deferred by {{ ballot.deferred_by }} on {{ ballot.deferred_date }}.</div>
42-
{% else %}
43-
<div style="margin-top:8px; margin-bottom:8px;"><span id="doc_defer_ballot_button" class="yui-button yui-link-button"><span class="first-child"><a href="{% url doc_defer_ballot name=doc %}">Defer ballot</a></span></span></div>
4436
{% endif %}
37+
38+
<form class="position-form" action="" method="POST">
39+
40+
<div>
41+
<span class="position">{{ form.position }}</span>
42+
<span class="actions">
43+
<input type="submit" name="send_mail" value="Save and send email"/>
44+
<input type="submit" value="Save"/>
45+
{% if ballot.was_deferred %}<input type="submit" name="Undefer" value="Undefer"/>{% else %}<input type="submit" name="Defer" value="Defer"/>{% endif %}
46+
</span>
4547
</div>
4648

4749
<div style="clear:left"></div>
48-
50+
4951
<div class="discuss-widgets">
5052
<div class="discuss-text">
5153
{{ form.discuss_text.label_tag }}:
5254
{% if discuss %}<span class="last-edited">(last edited {{ discuss.date }})</span>{% endif %}
5355
</div>
56+
{{ form.discuss_text.errors }}
5457
{{ form.discuss_text }}
5558
</div>
5659

@@ -62,12 +65,10 @@ <h1>Change position for {{ ad }} on {{ doc }}</h1>
6265

6366
<div class="actions">
6467
<a href="{{ return_to_url }}">Back</a>
65-
<input type="submit" name="send_mail" value="Save and send email"/>
66-
<input type="submit" value="Save"/>
6768
</div>
68-
69-
{{ form.return_to_url }}
7069

70+
{{ form.return_to_url }}
71+
7172
</form>
7273
{% endblock %}
7374

ietf/templates/idrfc/last_call_announcement.txt

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,13 @@ The IESG has received a request from {{ group }} to consider the following docum
1111

1212
The IESG plans to make a decision in the next few weeks, and solicits final comments on this action. Please send substantive comments to the ietf@ietf.org mailing lists by {{ expiration_date }}. Exceptionally, comments may be sent to iesg@ietf.org instead. In either case, please retain the beginning of the Subject line to allow automated sorting.{% endfilter %}
1313

14+
Abstract{{ docs|pluralize }}
15+
16+
{% for d in docs %}
17+
{{ d.abstract}}
18+
19+
{% endfor %}
20+
1421
The file{{ urls|pluralize }} can be obtained via
1522
{% for u in urls %}{{ u }}
1623
{% endfor %}{% if impl_report %}

ietf/templates/idrfc/undefer_ballot.html

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,8 @@ <h1>Undefer ballot for {{ doc }}</h1>
88
<form action="" method="POST">
99
<p>Undefer the ballot for {{ doc.file_tag }}?</p>
1010

11+
<p>The ballot will then be on the IESG agenda of {{ telechat_date }}.</p>
12+
1113
<div class="actions">
1214
<a href="{{ doc.idinternal.get_absolute_url }}">Back</a>
1315
<input type="submit" value="Undefer ballot"/>

static/js/lib/jquery-1.5.1.min.js

Lines changed: 16 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)