Update IESG agenda pages with IANA Review state, consensus and last

call expiration (if applicable)
 - Legacy-Id: 4852
This commit is contained in:
Ole Laursen 2012-09-17 15:59:35 +00:00
parent 85d2cdddc2
commit 0ec0fa58f3
5 changed files with 69 additions and 12 deletions

View file

@ -56,7 +56,7 @@ from ietf.idrfc.utils import update_telechat
from ietf.ietfauth.decorators import group_required
from ietf.idtracker.templatetags.ietf_filters import in_group
from ietf.ipr.models import IprDocAlias
from ietf.doc.models import Document, TelechatDocEvent
from ietf.doc.models import Document, TelechatDocEvent, LastCallDocEvent, ConsensusDocEvent
from ietf.group.models import Group
def date_threshold():
@ -193,20 +193,33 @@ if settings.USE_DB_REDESIGN_PROXY_CLASSES:
get_doc_section = get_doc_sectionREDESIGN
def agenda_docs(date, next_agenda):
from ietf.doc.models import TelechatDocEvent
matches = Document.objects.filter(docevent__telechatdocevent__telechat_date=date).distinct()
matches = Document.objects.filter(docevent__telechatdocevent__telechat_date=date).select_related("stream").distinct()
docmatches = []
for m in matches:
if m.latest_event(TelechatDocEvent, type="scheduled_for_telechat").telechat_date != date:
for doc in matches:
if doc.latest_event(TelechatDocEvent, type="scheduled_for_telechat").telechat_date != date:
continue
e = m.latest_event(type="started_iesg_process")
m.balloting_started = e.time if e else datetime.datetime.min
e = doc.latest_event(type="started_iesg_process")
doc.balloting_started = e.time if e else datetime.datetime.min
docmatches.append(m)
if doc.type_id == "draft":
s = doc.get_state("draft-iana-review")
if s and s.slug in ("not-ok", "changed", "need-rev"):
doc.iana_review_state = str(s)
if doc.get_state_slug("draft-iesg") == "lc":
e = doc.latest_event(LastCallDocEvent, type="sent_last_call")
if e:
doc.lastcall_expires = e.expires
doc.consensus = "Unknown"
e = doc.latest_event(ConsensusDocEvent, type="changed_consensus")
if e:
doc.consensus = "Yes" if e.consensus else "No"
docmatches.append(doc)
res = dict(("s%s%s%s" % (i, j, k), []) for i in range(2, 5) for j in range (1, 4) for k in range(1, 4))
for id in docmatches:
@ -314,6 +327,22 @@ def _agenda_json(request, date=None):
if defer:
docinfo['defer-by'] = defer.by.name
docinfo['defer-at'] = str(defer.time)
if doc.type_id == "draft":
iana_state = doc.get_state("draft-iana-review")
if iana_state.slug in ("not-ok", "changed", "need-rev"):
docinfo['iana_review_state'] = str(iana_state)
if doc.get_state_slug("draft-iesg") == "lc":
e = doc.latest_event(LastCallDocEvent, type="sent_last_call")
if e:
docinfo['lastcall_expires'] = e.expires
docinfo['consensus'] = None
e = doc.latest_event(ConsensusDocEvent, type="changed_consensus")
if e:
docinfo['consensus'] = e.consensus
data['sections'][s]['docs'] += [docinfo, ]
wgs = agenda_wg_actions(date)

View file

@ -46,6 +46,7 @@ OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. #}
.agenda blockquote { margin-left: 30px; width: 70ex; font-style:italic;}
table.agenda-doc { margin-left: 30px; margin-top:0.5em; margin-bottom: 0.5em; width: 95%; }
table.agenda-doc > tbody > tr { vertical-align:top; }
.agenda .stream { padding-left: 0.5em; }
{% endblock morecss %}
{% block pagehead %}

View file

@ -106,6 +106,8 @@ Some parts Copyright (c) 2009 The IETF Trust, all rights reserved.
{% endif %}
{% endwith %}
<span class="stream">{% if doc.obj.stream %} - {{ doc.obj.stream }} stream{% endif %}</span>
<br/>{{ doc.obj.title|escape }} ({{ doc.obj.intended_std_level }})
@ -132,6 +134,19 @@ Some parts Copyright (c) 2009 The IETF Trust, all rights reserved.
<br/>Was deferred by {{defer.by}} on {{defer.time|date:"Y-m-d"}}
{% endif %}
{% endwith %}
{% if doc.obj.iana_review_state %}
<br/>IANA Review: {{ doc.obj.iana_review_state }}
{% endif %}
{% if doc.obj.consensus %}
<br/>Consensus: {{ doc.obj.consensus }}
{% endif %}
{% if doc.obj.lastcall_expires %}
<br/>Last call expires: {{ doc.obj.lastcall_expires|date:"Y-m-d" }}
{% endif %}
</td><td style="padding-left:20px; width: 50px;">
{% ballot_icon doc.obj %}
</td></tr></tbody></table>

View file

@ -39,10 +39,13 @@ Some parts Copyright (c) 2009 The IETF Trust, all rights reserved.
{{ title2 }}
{% endif %}{{ title3 }}
{% for doc in section_docs %}{% with doc.obj.rfc_number as rfc_number %}
o {{doc.obj.canonical_name}}{% if not rfc_number %}-{{doc.obj.rev}}{% endif %}{% endwith %}
o {{doc.obj.canonical_name}}{% if not rfc_number %}-{{doc.obj.rev}}{% endif %}{% endwith %}{% if doc.obj.stream %} - {{ doc.obj.stream }} stream{% endif %}
{% filter wordwrap:"68"|indent|indent %}{{ doc.obj.title }} ({{ doc.obj.intended_std_level }}){% endfilter %}
{% if doc.obj.note %}{# note: note is not escaped #} {% filter wordwrap:"68"|indent|indent %}Note: {{ doc.obj.note|striptags }}{% endfilter %}
{% endif %} Token: {{ doc.obj.ad }}
{% endif %} Token: {{ doc.obj.ad }}{% if doc.obj.iana_review_state %}
IANA Review: {{ doc.obj.iana_review_state }}{% endif %}{% if doc.obj.consensus %}
Consensus: {{ doc.obj.consensus }}{% endif %}{% if doc.obj.lastcall_expires %}
Last call expires: {{ doc.obj.lastcall_expires|date:"Y-m-d" }}{% endif %}
{% with doc.obj.active_defer_event as defer %}{% if defer %} Was deferred by {{defer.by}} on {{defer.time|date:"Y-m-d"}}{% endif %}{% endwith %}
{% empty %}
NONE

View file

@ -53,10 +53,19 @@ Some parts Copyright (c) 2009 The IETF Trust, all rights reserved.
<a href="http://www.ietf.org/id/{{doc.obj.canonical_name}}-{{doc.obj.rev}}.txt">[txt]</a>
{% endif %}
{% endwith %}
<span class="stream">{% if doc.obj.stream %} - {{ doc.obj.stream }} stream{% endif %}</span>
<br/>Token: {{ doc.obj.ad|escape }} ({{doc.obj.area_acronym}} area)
{% if doc.obj.note %}{# note: note is not escaped #}
{% if doc.obj.note %}{# note: note is not escaped #}
<br/>Note: {{ doc.obj.note|safe }}
{% endif %}
{% if doc.obj.iana_review_state %}
<br/>IANA Review: {{ doc.obj.iana_review_state }}
{% endif %}
{% if doc.obj.consensus %}
<br/>Consensus: {{ doc.obj.consensus }}
{% endif %}
{% for ipr in doc.obj.ipr %}
{% ifequal ipr.ipr.status 1 %}
<br/>IPR: <a href="http://datatracker.ietf.org/ipr/{{ ipr.ipr.ipr_id }}/">{{ ipr.ipr.title|escape }}</a>