Added an index page for nomcoms, at /nomcom/, with links to nomcom pages and announcements, where they exist.

- Legacy-Id: 6245
This commit is contained in:
Henrik Levkowetz 2013-09-22 18:59:24 +00:00
parent c52efcae8c
commit 0016c69b61
4 changed files with 63 additions and 23 deletions

View file

@ -20,6 +20,7 @@ from django.forms.models import modelformset_factory, inlineformset_factory
from ietf.dbtemplate.models import DBTemplate
from ietf.dbtemplate.views import template_edit
from ietf.name.models import NomineePositionState, FeedbackType
from ietf.group.models import Group
from ietf.nomcom.decorators import nomcom_private_key_required
from ietf.nomcom.forms import (NominateForm, FeedbackForm, QuestionnaireForm,
@ -33,9 +34,33 @@ from ietf.nomcom.utils import (get_nomcom_by_year, store_nomcom_private_key,
HOME_TEMPLATE, NOMINEE_REMINDER_TEMPLATE)
from ietf.ietfauth.utils import role_required
import debug
def index(request):
nomcom_list = NomCom.objects.all()
nomcom_list = Group.objects.filter(type__slug='nomcom').order_by('acronym')
for nomcom in nomcom_list:
year = nomcom.acronym[6:]
debug.show('year')
try:
year = int(year)
except ValueError:
year = None
debug.show('year')
nomcom.year = year
nomcom.label = "%s/%s" % (year, year+1)
if year in [ 2005, 2006, 2007, 2008, 2009, 2010 ]:
nomcom.url = "https://tools.ietf.org/group/nomcom/%02d" % (year % 100)
elif year in [ 2011, 2012 ]:
nomcom.url = "https://www.ietf.org/nomcom/%04d" % year
elif year > 2012:
nomcom.url = "/nomcom/%04d" % year
else:
nomcom.url = None
if year >= 2002:
nomcom.ann_url = "/ann/nomcom/#%4d" % year
else:
nomcom.ann_url = None
debug.show('nomcom.url')
return render_to_response('nomcom/index.html',
{'nomcom_list': nomcom_list,}, RequestContext(request))

View file

@ -9,7 +9,7 @@
{% for regime in regimes %}
<hr>
<h1>Messages from {{ regime.group.start_year }} - {{ regime.group.end_year }}</h1>
<h1 id="{{regime.group.start_year}}">Messages from {{ regime.group.start_year }} - {{ regime.group.end_year }}</h1>
{# use person email address here rather than the generic nomcom-chair@ietf.org #}
<h4>Committee Chair: <a href="mailto:{{ regime.chair.person.email_address }}">{{ regime.chair.person.plain_name }}</a></h4>
@ -33,7 +33,7 @@
{# somebody ought to import these announcements in the DB instead of this mess #}
<h3>Messages from 2003-2004 NomCom</h3>
<h3 id="2003">Messages from 2003-2004 NomCom</h3>
Committee Chair: <A HREF="mailto:richdr@microsoft.com">Rich Draves</A>
<br><br><li><a href="http://www.ietf.org/old/2009/nomcom/msg08-25-2003.txt">IETF Nominations Committee Chair Announcement</a> August 25, 2003
<LI><a href="http://www.ietf.org/old/2009/nomcom/msg09.22.txt">NomCom call for volunteers</a> September 22, 2003
@ -51,7 +51,7 @@ Committee Chair: <A HREF="mailto:richdr@microsoft.com">Rich Draves</A>
<LI><A HREF="http://www.ietf.org/old/2009/nomcom/msg09.28.txt">Call for Security AD nominations</a> September 28, 2004
<LI><A HREF="http://www.ietf.org/old/2009/nomcom/msg11.07.04.txt">Steve Bellovin replacement</a> November 07, 2004
<h3>Messages from 2002-2003 NomCom</h3>
<h3 id="2002">Messages from 2002-2003 NomCom</h3>
Committee Chair: <A HREF="mailto:PRoberts@MEGISTO.com">Phil Roberts</A>
<br><br>

View file

@ -1,24 +1,37 @@
{% extends "nomcom/nomcom_base.html" %}
{# Copyright The IETF Trust 2009, All Rights Reserved #}
{% extends "base.html" %}
{% load ietf_filters %}
{% block title %}IAB/IESG NomcOms{% endblock %}
{% load nomcom_tags %}
{% block content %}
<h1>IAB/IESG NomComs</h1>
<h1>Nomcom Pages</h1>
<div class="ietf-navset">
{% if selected == "index" %}<span class="selected">Home</span>{% else %}<a href="{% url nomcom_year_index year %}">Home</a>{% endif %} |
{% if nomcom|has_publickey %}
{% if selected == "nominate" %}<span class="selected">Nominate</span>{% else %}<a href="{% url nomcom_public_nominate year %}">Nominate</a>{% endif %} |
{% if selected == "feedback" %}<span class="selected">Provide Comments</span>{% else %}<a href="{% url nomcom_public_feedback year %}">Provide Comments</a>{% endif %} |
{% endif %}
{% if selected == "requirements" %}<span class="selected">Requirements</span>{% else %}<a href="{% url nomcom_requirements year %}">Requirements</a>{% endif %} |
{% if selected == "questionnaires" %}<span class="selected">Questionnaires</span>{% else %}<a href="{% url nomcom_questionnaires year %}">Questionnaires</a>{% endif %} |
</div>
{% block nomcom_content %}
{% endblock %}
<div style="margin-left:2em;">
<table class="ietf-doctable">
<tr>
<th>Year</th>
<th>Chair</th>
<th></th>
<th></th>
</tr>
{% for nomcom in nomcom_list %}
<tr>
<td>{{ nomcom.label }}</td>
<td >{% with nomcom.get_chair as role %}<a href="mailto:{{role.person.email_address}}">{{role.person}}</a>{% endwith %}</td>
<td >
{% if nomcom.ann_url %}
<a href="{{ nomcom.ann_url }}">Announcements</a>
{% endif %}
</td>
<td >
{% if nomcom.url %}
<a href="{{ nomcom.url }}">Pages</a>
{% endif %}
</td>
</tr>
{% endfor %}
</table>
</div>
{% endblock %}

View file

@ -137,9 +137,11 @@ table.ietf-table { border-collapse:collapse; border:1px solid #7f7f7f; }
.ietf-doctable th.status, .ietf-doctable td.status { min-width: 20em;}
.ietf-doctable th.ipr { font-variant: small-caps; }
.ietf-doctable th.ad, .ietf-doctable td.ad { white-space:nowrap; min-width: 6em; }
.ietf-doctable td { padding-right: 0.5em; padding-left: 0.5em; }
.ietf-doctable td.ballot { border-left: hidden; min-width: 37px; }
.ietf-doctable td .updated-by { max-width: 20em; } /* some RFCs have really long lists */
.ietf-doctable .status .milestone,
.ietf-box .stream-state .milestone
{ display: inline-block; font-size: smaller; background-color: #d5dde6; padding: 0 0.2em; margin-left: 0.3em; }