Skip to content

Commit

Permalink
Adding page to allow viewing meeting slot requests as they are made. …
Browse files Browse the repository at this point in the history
…There's no link

to these yet.
 - Legacy-Id: 3246
  • Loading branch information
adamroach committed Jul 23, 2011
1 parent 1a6f720 commit 4f9e90d
Show file tree
Hide file tree
Showing 4 changed files with 141 additions and 0 deletions.
2 changes: 2 additions & 0 deletions ietf/meeting/urls.py
Expand Up @@ -7,13 +7,15 @@
(r'^(?P<meeting_num>\d+)/materials.html$', views.show_html_materials),
(r'^agenda/$', views.html_agenda),
(r'^agenda(?:.html)?$', views.html_agenda),
(r'^requests.html$', views.meeting_requests),
(r'^agenda.txt$', views.text_agenda),
(r'^agenda/agenda.ics$', views.ical_agenda),
(r'^agenda.ics$', views.ical_agenda),
(r'^agenda.csv$', views.csv_agenda),
(r'^agenda/week-view.html$', views.week_view),
(r'^week-view.html$', views.week_view),
(r'^(?P<num>\d+)/agenda(?:.html)?/?$', views.html_agenda),
(r'^(?P<num>\d+)/requests.html$', views.meeting_requests),
(r'^(?P<num>\d+)/agenda.txt$', views.text_agenda),
(r'^(?P<num>\d+)/agenda.ics$', views.ical_agenda),
(r'^(?P<num>\d+)/agenda.csv$', views.csv_agenda),
Expand Down
19 changes: 19 additions & 0 deletions ietf/meeting/views.py
Expand Up @@ -360,3 +360,22 @@ def csv_agenda(request, num=None):
{"timeslots":timeslots, "update":update, "meeting":meeting, "venue":venue, "ads":ads,
"plenaryw_agenda":plenaryw_agenda, "plenaryt_agenda":plenaryt_agenda, },
RequestContext(request)), mimetype="text/csv")

def meeting_requests(request, num=None) :
timeslots, update, meeting, venue, ads, plenaryw_agenda, plenaryt_agenda = agenda_info(num)
sessions = WgMeetingSession.objects.filter(meeting=meeting)

wgs = IETFWG.objects.filter(status=IETFWG.ACTIVE).order_by("group_acronym__acronym");
rgs = IRTF.objects.all().order_by('acronym')
areas = Area.objects.filter(status=Area.ACTIVE).order_by('area_acronym__acronym')
return render_to_response("meeting/requests.html",
{"sessions": sessions, "timeslots":timeslots, "update":update, "meeting":meeting, "venue":venue, "ads":ads, "wgs":wgs,
"plenaryw_agenda":plenaryw_agenda, "plenaryt_agenda":plenaryt_agenda, "areas":areas},
context_instance=RequestContext(request))

def conflict_digraph(request, num=None) :
timeslots, update, meeting, venue, ads, plenaryw_agenda, plenaryt_agenda = agenda_info(num)
sessions = WgMeetingSession.objects.filter(meeting=meeting)
return render_to_response("meeting/digraph.html",
{"sessions":sessions},
context_instance=RequestContext(request), mimetype="text/plain")
17 changes: 17 additions & 0 deletions ietf/proceedings/models.py
Expand Up @@ -448,6 +448,15 @@ def interim_meeting (self):
return True
else:
return False
def length_session1_desc (self):
mh = MeetingHour.objects.get(hour_id=self.length_session1)
return mh.hour_desc
def length_session2_desc (self):
mh = MeetingHour.objects.get(hour_id=self.length_session2)
return mh.hour_desc
def length_session3_desc (self):
mh = MeetingHour.objects.get(hour_id=self.length_session3)
return mh.hour_desc
class Meta:
db_table = 'wg_meeting_sessions'
verbose_name = "WG meeting session"
Expand Down Expand Up @@ -566,6 +575,14 @@ class Meta:
db_table = 'wg_proceedings_activities'
verbose_name = "WG material upload"

class MeetingHour(models.Model):
hour_id = models.IntegerField(primary_key=True)
hour_desc = models.CharField(max_length=60, blank=True)
def __unicode__(self):
return self.hour_desc
class Meta:
db_table = u'meeting_hours'

# changes done by convert-096.py:changed maxlength to max_length
# removed core
# removed raw_id_admin
103 changes: 103 additions & 0 deletions ietf/templates/meeting/requests.html
@@ -0,0 +1,103 @@
{% extends "base.html" %}{% load ietf_filters %}
{# Copyright The IETF Trust 2007, All Rights Reserved #}
{% block title %}IETF {{ meeting.num }} Meeting Timeslot Requests{% endblock %}
{% block morecss %}
h2 { border-style: none none solid none }
h3 { color: #0000a0 }
th { text-align: right; vertical-align: text-top; }
{% endblock morecss %}

{% block content %}
<h1>IETF {{ meeting.num }} Meeting Timeslot Requests</h1>

{# cache for 15 minutes -- XXX need to add criteria #}
{% load cache %}
{% cache 900 meeting.num %}
{% endcache %}

{% regroup sessions|dictsort:"area" by area as area_list %}
{% for area in area_list %}
{% if area.grouper %}{% ifnotequal area.grouper|upper "1PLENARY" %}
<h2>{{area.grouper|upper}}</h2>

<h3>Summary</h3>
<table>
{% for session in area.list|dictsort:"acronym" %}
{% if session.length_session1 %}
<tr>
<th>{{session.acronym|upper}}: </th>
<td>
{{session.length_session1_desc}}
{% ifnotequal session.length_session2 "0" %}
+ {{session.length_session2_desc}}
{% endifnotequal %}
{% ifnotequal session.length_session3 "0" %}
+ {{session.length_session3_desc}}
{% endifnotequal %}
</td>
</tr>
{% endif %}
{% endfor %}
<tr><th>Unscheduled:</th><td>
{% for wg in wgs %}
{% ifequal wg.area_acronym|upper area.grouper|upper %}
{% ifequal wg.meeting_scheduled|upper "NO" %}
{{wg|upper}}
{% endifequal %}
{% endifequal %}
{% endfor %}
</td></tr>
</table>


{% for session in area.list|dictsort:"acronym" %}
{% if session.length_session1 %}
<h3>{{session.acronym|upper}}</h3>
<table>
<tr><th>Requested&nbsp;By: </th>
<td>{{session.requested_by}} on {{session.requested_date}}
{% ifnotequal session.requested_date session.last_modified_date %}
(modified {{session.last_modified_date}})
{% endifnotequal %}
</td>
</tr>
<tr>
<th>Session&nbsp;Length: </th>
<td>
{{session.length_session1_desc}}
{% ifnotequal session.length_session2 "0" %}
+ {{session.length_session2_desc}}
{% endifnotequal %}
{% ifnotequal session.length_session3 "0" %}
+ {{session.length_session3_desc}}
{% endifnotequal %}
</td>
</tr>
{% if session.conflict1 %}
<tr><th>Primary&nbsp;Conflicts: </th><td>{{session.conflict1}}</td></tr>
{% endif %}
{% if session.conflict2 %}
<tr><th>Secondary&nbsp;Conflicts: </th><td>{{session.conflict2}}</td></tr>
{% endif %}
{% if session.conflict3 %}
<tr><th>Tertiary&nbsp;Conflicts: </th><td>{{session.conflict3}}</td></tr>
{% endif %}
{% if session.conflict_other %}
<tr><th>Other&nbsp;Conflicts: </th><td>{{session.conflict_other}}</td></tr>
{% endif %}
{% if session.special_req %}
<tr><th>Special&nbsp;Requests: </th><td>{{session.special_req}}</td></tr>
{% endif %}
{% if session.ad_comments %}
<tr><th>AD&nbsp;Comments: </th><td>{{session.ad_comments}}</td></tr>
{% endif %}
<table>
{% endif %}

{%endfor%}
{% endifnotequal %}{% endif %}
{% endfor %}
<br>


{% endblock %}

0 comments on commit 4f9e90d

Please sign in to comment.