Enhanced [17687] slightly, adding rendering of other status settings than cancelled, and adding warning background for cancelled. See issue #2963.

- Legacy-Id: 17688
Note: SVN reference [17687] has been migrated to Git commit 48562d131b
This commit is contained in:
Henrik Levkowetz 2020-04-25 14:34:56 +00:00
parent 48562d131b
commit 8a7f4ce96e
2 changed files with 4 additions and 1 deletions

View file

@ -1139,12 +1139,15 @@ def session_details(request, num, acronym):
else:
session.times = [ x.timeslot.local_start_time() for x in ss ]
session.cancelled = session.current_status == 'canceled'
session.status = ''
elif meeting.type_id=='interim':
session.times = [ meeting.date ]
session.cancelled = session.current_status == 'canceled'
session.status = ''
else:
session.times = []
session.cancelled = session.current_status == 'canceled'
session.status = status_names.get(session.current_status, session.current_status)
session.filtered_artifacts = list(session.sessionpresentation_set.filter(document__type__slug__in=['agenda','minutes','bluesheets']))
session.filtered_artifacts.sort(key=lambda d:['agenda','minutes','bluesheets'].index(d.document.type.slug))

View file

@ -3,7 +3,7 @@
{% for session in sessions %}
<h2 class="anchor-target" id="session_{{session.pk}}">{% if sessions|length > 1 %}Session {{ forloop.counter }} : {% endif %}
{% for time in session.times %}{% if not forloop.first %}, {% endif %} {{time|dateformat:"l Y-m-d H:i T"}} {% if time.tzinfo.zone != "UTC" %}<span class="small">({{time|utc|dateformat:"H:i T"}})</span>{% endif %}{% endfor %}
{% if session.cancelled %}<span class="error">CANCELLED</span>{% endif %}
{% if session.cancelled %}<small class="label label-warning">CANCELLED</small>{% else %}{{ session.status }}{% endif %}
{% if session.name %} : {{ session.name }}{% endif %}
{% if meeting.date >= thisweek %}
<a class="regular pull-right" title="icalendar entry for {{acronym}} session {{ forloop.counter }}" href="{% url 'ietf.meeting.views.ical_agenda' num=meeting.number session_id=session.id %}"><span class="fa fa-calendar"></span></a>