Skip to content

Commit 0a34a90

Browse files
author
Martin Qvist
committed
Final version of charter tool in a new branch
- Legacy-Id: 3341
1 parent f87a378 commit 0a34a90

76 files changed

Lines changed: 4452 additions & 92 deletions

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

ietf/idrfc/testsREDESIGN.py

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -189,7 +189,6 @@ def test_edit_info(self):
189189
status_date=str(date.today() + timedelta(2)),
190190
via_rfc_editor="1",
191191
ad=str(new_ad.pk),
192-
create_in_state="pub-req",
193192
notify="test@example.com",
194193
note="New note",
195194
telechat_date="",
@@ -214,7 +213,6 @@ def test_edit_telechat_date(self):
214213
data = dict(intended_std_level=str(draft.intended_std_level_id),
215214
status_date=str(date.today() + timedelta(2)),
216215
via_rfc_editor="1",
217-
create_in_state="pub-req",
218216
ad=str(draft.ad_id),
219217
notify="test@example.com",
220218
note="",
@@ -275,7 +273,6 @@ def test_start_iesg_process_on_draft(self):
275273
status_date=str(date.today() + timedelta(2)),
276274
via_rfc_editor="1",
277275
ad=ad.pk,
278-
create_in_state="watching",
279276
notify="test@example.com",
280277
note="This is a note",
281278
telechat_date="",
@@ -284,7 +281,6 @@ def test_start_iesg_process_on_draft(self):
284281

285282
draft = Document.objects.get(name=draft.name)
286283
self.assertTrue(draft.tags.filter(slug="via-rfc"))
287-
self.assertEquals(draft.iesg_state_id, "watching")
288284
self.assertEquals(draft.ad, ad)
289285
self.assertEquals(draft.note, "This is a note")
290286
self.assertTrue(not draft.latest_event(TelechatDocEvent, type="scheduled_for_telechat"))

ietf/idtracker/models.py

Lines changed: 12 additions & 31 deletions
Original file line numberDiff line numberDiff line change
@@ -183,9 +183,6 @@ def file_tag(self):
183183
return "<%s>" % (self.filename_with_rev())
184184
def filename_with_rev(self):
185185
return "%s-%s.txt" % (self.filename, self.revision_display())
186-
def name(self):
187-
# small hack to make model forward-compatible with new schema
188-
return self.filename
189186
def group_acronym(self):
190187
return self.group.acronym
191188
def group_ml_archive(self):
@@ -258,11 +255,11 @@ class PersonOrOrgInfo(models.Model):
258255
date_created = models.DateField(auto_now_add=True, null=True)
259256
created_by = models.CharField(blank=True, null=True, max_length=8)
260257
address_type = models.CharField(blank=True, null=True, max_length=4)
261-
def save(self, **kwargs):
258+
def save(self):
262259
self.first_name_key = self.first_name.upper()
263260
self.middle_initial_key = self.middle_initial.upper()
264261
self.last_name_key = self.last_name.upper()
265-
super(PersonOrOrgInfo, self).save(**kwargs)
262+
super(PersonOrOrgInfo, self).save()
266263
def __str__(self):
267264
# For django.VERSION 0.96
268265
if self.first_name == '' and self.last_name == '':
@@ -276,12 +273,16 @@ def __unicode__(self):
276273
def email(self, priority=1, type=None):
277274
name = unicode(self)
278275
email = ''
279-
addresses = self.emailaddress_set.filter(address__contains="@").order_by('priority')
280-
if addresses:
281-
email = addresses[0].address
282-
for a in addresses:
283-
if a.priority == priority:
284-
email = a.address
276+
types = type and [ type ] or [ "INET", "Prim", None ]
277+
for type in types:
278+
try:
279+
if type:
280+
email = self.emailaddress_set.get(priority=priority, type=type).address
281+
else:
282+
email = self.emailaddress_set.get(priority=priority).address
283+
break
284+
except (EmailAddress.DoesNotExist, AssertionError):
285+
pass
285286
return (name, email)
286287
# Added by Sunny Lee to display person's affiliation - 5/26/2007
287288
def affiliation(self, priority=1):
@@ -409,9 +410,6 @@ def displayname(self):
409410
return "%s.txt" % ( self.filename() )
410411
def filename(self):
411412
return "rfc%d" % ( self.rfc_number )
412-
def name(self):
413-
# small hack to make model forward-compatible with new schema
414-
return self.filename()
415413
def revision(self):
416414
return "RFC"
417415
def revision_display(self):
@@ -1139,23 +1137,6 @@ class DocumentWrapper(object):
11391137
def __init__(self, document):
11401138
self.document = document
11411139

1142-
if settings.USE_DB_REDESIGN_PROXY_CLASSES:
1143-
InternetDraftOld = InternetDraft
1144-
IDInternalOld = IDInternal
1145-
RfcOld = Rfc
1146-
BallotInfoOld = BallotInfo
1147-
IDStateOld = IDState
1148-
IDSubStateOld = IDSubState
1149-
AreaOld = Area
1150-
AcronymOld = Acronym
1151-
IESGLoginOld = IESGLogin
1152-
IETFWGOld = IETFWG
1153-
IRTFOld = IRTF
1154-
from redesign.doc.proxy import InternetDraft, IDInternal, BallotInfo, Rfc
1155-
from redesign.name.proxy import IDState, IDSubState
1156-
from redesign.group.proxy import Area, Acronym, IETFWG, IRTF
1157-
from redesign.person.proxy import IESGLogin
1158-
11591140

11601141
# changes done by convert-096.py:changed maxlength to max_length
11611142
# removed core

ietf/settings.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -145,6 +145,7 @@
145145
'ietf.submit',
146146
'ietf.ietfworkflows',
147147
'ietf.wgchairs',
148+
'ietf.wgrecord',
148149
)
149150

150151
INTERNAL_IPS = (

ietf/templates/base_leftmenu.html

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -40,12 +40,12 @@
4040
<li><a href="{% url doc_search_by_ad name=user.get_profile.person.full_name_as_key %}">My Documents</a></li>
4141
<li><a href="{% url ietf.iesg.views.agenda_documents %}">Next Telechat</a></li>
4242
<li><a href="{% url ietf.iesg.views.discusses %}">Discusses</a></li>
43-
<li><a href="{% url iesg_working_group_actions %}">Working Groups</a></li>
43+
<li><a href="{% url wg_search_by_ad name=user.get_profile.person.full_name_as_key %}">Working Groups</a></li>
4444
{% endif %}
4545
{% if user|in_group:"Secretariat" %}
4646
<li class="sect first">Secretariat</li>
4747
<li><a href="{% url ietf.iesg.views.telechat_dates %}">Telechat Dates</a></li>
48-
<li><a href="{% url iesg_working_group_actions %}">Working Groups</a></li>
48+
<li><a href="{% url wg_search_in_process %}">Working Groups</a></li>
4949
{% endif %}
5050
<li class="sect{% if not user|in_group:"Area_Director,Secretariat" %} first{% endif %}">Working Groups</li>
5151

@@ -74,6 +74,7 @@
7474
<li><a href="http://www.ietf.org/meeting/upcoming.html">Upcoming</a></li>
7575

7676
<li class="sect">Other Documents</li>
77+
<li><a href="/wgrecord/">WG Records</a></li>
7778
<li><a href="/ipr/">IPR Disclosures</a></li>
7879
<li><a href="/liaison/">Liaison&nbsp;Statements</a></li>
7980
<li><a href="/iesg/agenda/">IESG Agenda</a></li>
Lines changed: 28 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,28 @@
1+
{# Copyright The IETF Trust 2011, All Rights Reserved #}
2+
{% load ietf_filters %}
3+
{{ obj.info.text|safe }}<br/>
4+
<br/>
5+
{% with obj.group as wg %}
6+
WG name: {{ wg.name }}<br/>
7+
WG acronym: {{ wg.acronym }}<br/>
8+
IETF area: {{ wg.parent|default:"-" }}<br/>
9+
10+
WG chairs: {% for n in obj.chairs %}{{ n }}{% if not forloop.last %}, {% endif %}{% endfor %}<br/>
11+
WG secretaries: {% for n in obj.secr %}{{ n }}{% if not forloop.last %}, {% endif %}{% endfor %}<br/>
12+
WG technical advisors: {% for n in obj.techadv %}{{ n }}{% if not forloop.last %}, {% endif %}{% endfor %}<br/>
13+
Assigned AD: {{ wg.ad }}<br/>
14+
15+
Mailing list: {{ wg.list_email }}<br/>
16+
Mailing list subscribe {{ wg.list_subscribe }}<br/>
17+
Mailing list archive: {{ wg.list_archive }}<br/>
18+
Other web sites: {% for a in wg.groupurl_set.all %}{{ a.url }} {% if a.name %}({{ a.name }}){% endif %}{% if not forloop.last %}, {% endif %}{% endfor %}<br/>
19+
20+
WG State: {{ wg.state|safe }}<br/>
21+
Charter State: {{ wg.charter.charter_state|safe }}<br/>
22+
<br/>
23+
{% if obj.rev %}
24+
{{ obj.charter|safe }}
25+
{% else %}
26+
The WG does not yet have a charter
27+
{% endif %}
28+
{% endwith %}
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
{% load ietf_filters %}WG Record for {{obj.group.name}} ({{ obj.group.acronym|safe }})

ietf/templates/idrfc/edit_infoREDESIGN.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
{% block title %}Edit info on {{ doc }}{% endblock %}
44

55
{% block morecss %}
6-
form.edit-info #id_notify {
6+
form.edit-info #id_state_change_notice_to {
77
width: 600px;
88
}
99
form.edit-info #id_note {

ietf/templates/wginfo/wg_base.html

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -49,11 +49,13 @@
4949
.ietf-wg-details tr { vertical-align: top; }
5050
.ietf-concluded-bg {background-color: #F8F8D0; }
5151
.ietf-concluded-warning { background:red;color:white;padding:2px 2px;}
52+
.ietf-proposed-bg { }
53+
.ietf-proposed-warning { background:green;color:white;padding:2px 2px;}
5254
{% endblock morecss %}
5355

5456
{% block content %}
55-
<div {% if concluded %}class="ietf-concluded-bg"{% endif %}>
56-
<h1>{{wg.group_acronym.name}} ({{wg.group_acronym.acronym}}){% if concluded %}<br/><span class="ietf-concluded-warning">(concluded WG)</span>{% endif %}</h1>
57+
<div {% if concluded %}class="ietf-concluded-bg"{% endif %} {% if proposed %}class="ietf-proposed-bg"{% endif %}>
58+
<h1>{{wg.group_acronym.name}} ({{wg.group_acronym.acronym}}){% if concluded %}<br/><span class="ietf-concluded-warning">(concluded WG)</span>{% endif %}{% if proposed %}<br/><span class="ietf-proposed-warning">(proposed WG)</span>{% endif %}</h1>
5759

5860
<div class="ietf-navset">
5961
{% ifequal selected "documents" %}<span class="selected">Documents</span>{% else %}<a href="/wg/{{wg}}/">Documents</a>{% endifequal %} |
Lines changed: 36 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,36 @@
1+
{% extends "base.html" %}
2+
{% comment %}
3+
Copyright The IETF Trust 2011, All Rights Reserved
4+
{% endcomment %}
5+
6+
{% block title %}Add comment on {{ wg.acronym }}{% endblock %}
7+
8+
{% block morecss %}
9+
form.add-comment #id_comment {
10+
width: 600px;
11+
height: 300px;
12+
}
13+
14+
form.add-comment .actions {
15+
padding-top: 20px;
16+
}
17+
{% endblock %}
18+
19+
{% block content %}
20+
<h1>Add comment on {{ wg.acronym }}</h1>
21+
22+
<p>The comment will be added to the history trail.</p>
23+
24+
<form class="add-comment" action="" method="POST">
25+
<table>
26+
{{ form.as_table }}
27+
<tr>
28+
<td></td>
29+
<td class="actions">
30+
<a href="{% url record_view name=wg.acronym %}">Back</a>
31+
<input type="submit" value="Add comment"/>
32+
</td>
33+
</tr>
34+
</table>
35+
</form>
36+
{% endblock %}
Lines changed: 33 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,33 @@
1+
{% extends "base.html" %}
2+
3+
{% block title %}WG {{ announcement }} announcement writeup for {{ doc.group.acronym }}{% endblock %}
4+
5+
{% block morecss %}
6+
form #id_announcement_text {
7+
width: 700px;
8+
height: 600px;
9+
}
10+
{% endblock %}
11+
12+
{% block content %}
13+
<h1>WG {{ announcement }} announcement writeup for {{ doc.group.acronym }}</h1>
14+
15+
<form action="" method="POST">
16+
17+
{{ announcement_text_form.announcement_text }}
18+
19+
<div class="actions">
20+
<a href="{{ back_url }}">Back</a>
21+
<input type="submit" value="Save WG {{ announcement }} announcement text" />
22+
</div>
23+
</form>
24+
25+
{% load ietf_filters %}
26+
{% if user|in_group:"Secretariat" %}
27+
<p>
28+
{% if can_announce %}
29+
<a href="{% url doc_approve_ballot name=doc.name %}">Approve ballot</a>
30+
{% endif %}
31+
</p>
32+
{% endif %}
33+
{% endblock%}

0 commit comments

Comments
 (0)