Change the edit buttons on the materials page to be links. Move where the link appears. Commit ready for merge.

- Legacy-Id: 12318
This commit is contained in:
Robert Sparks 2016-11-12 03:07:46 +00:00
parent 0c816eaaf9
commit ca0980a8ea
3 changed files with 87 additions and 30 deletions

View file

@ -1,6 +1,9 @@
{% load ietf_filters session_filters %}
{% if session|can_manage_materials:user and not session.past_cutoff_date %}
{% with gt=session.group.type_id %}
{%comment%}
<a class="button btn-default btn-sm" href="{% url 'ietf.meeting.views.session_details' num=session.meeting.number acronym=session.group.acronym %}{% if gt == 'wg' or gt == 'rg' or gt == 'ag' %}{% else %}#session_{{session.pk}}{% endif %}">Edit</a>
{%endcomment%}
<a class="" href="{% url 'ietf.meeting.views.session_details' num=session.meeting.number acronym=session.group.acronym %}{% if gt == 'wg' or gt == 'rg' or gt == 'ag' %}{% else %}#session_{{session.pk}}{% endif %}">Edit materials</a>
{% endwith %}
{% endif %}

View file

@ -1,5 +1,5 @@
{# Copyright The IETF Trust 2015, All Rights Reserved #}{% load origin %}{% origin %}
{% load ietf_filters proceedings_filters %}
{% load ietf_filters proceedings_filters managed_groups %}
<tr>
<td>
{% comment %}
@ -8,9 +8,9 @@
<a name="session.group-{{ session.group.acronym }}"></a>
{% endcomment %}
{% if session.name %}
<div class="anchor-target" id="{{ session.name|slugify }}">{{ session.name }}{% include "meeting/edit_materials_button.html" %}</div>
<div class="anchor-target" id="{{ session.name|slugify }}">{{ session.name }}</div>
{% else %}
<div class="anchor-target" id="{{session.group.acronym}}"><a href="{% url 'ietf.group.views.group_home' acronym=session.group.acronym %}">{{session.group.acronym}}</a>{% include "meeting/edit_materials_button.html" %}</div>
<div class="anchor-target" id="{{session.group.acronym}}"><a href="{% url 'ietf.group.views.group_home' acronym=session.group.acronym %}">{{session.group.acronym}}</a></div>
{% if session.group.state.slug == "bof" %}
<span class="label label-success">{{ session.group.state.slug|upper }}</span>
{% endif %}
@ -18,7 +18,11 @@
</td>
{% if session.status_id == 'canceled' %}
<td colspan="3"><span class="label label-danger">Session cancelled</span></td>
{% if user and user.is_authenticated and user|managed_groups %}
<td colspan="4"><span class="label label-danger">Session cancelled</span></td>
{% else %}
<td colspan="3"><span class="label label-danger">Session cancelled</span></td>
{% endif %}
{% else %}
<td>
{% if session.agenda %}
@ -57,6 +61,11 @@
{% endfor %}
{% endwith %}
</td>
{% if user and user.is_authenticated and user|managed_groups %}
<td>
<div>{% include "meeting/edit_materials_button.html" %}</div>
</td>
{% endif %}
{% endif %}
</tr>

View file

@ -2,7 +2,7 @@
{# Copyright The IETF Trust 2015, All Rights Reserved #}
{% load origin %}
{% load ietf_filters staticfiles %}
{% load ietf_filters staticfiles managed_groups %}
{% block pagehead %}
<link rel="stylesheet" href="{% static "jquery.tablesorter/css/theme.bootstrap.min.css" %}">
@ -40,11 +40,20 @@
<table class="table table-condensed table-striped tablesorter">
<thead>
<tr>
<th class="col-md-1">Group</th>
<th class="col-md-1">Agenda</th>
<th class="col-md-1">Minutes</th>
<th class="col-md-6">Slides</th>
<th class="col-md-3">Drafts</th>
{% if user and user.is_authenticated and user|managed_groups %}
<th class="col-md-1">Group</th>
<th class="col-md-1">Agenda</th>
<th class="col-md-1">Minutes</th>
<th class="col-md-5">Slides</th>
<th class="col-md-2">Drafts</th>
<th class="col-md-2">&nbsp;</th>
{% else %}
<th class="col-md-1">Group</th>
<th class="col-md-1">Agenda</th>
<th class="col-md-1">Minutes</th>
<th class="col-md-6">Slides</th>
<th class="col-md-3">Drafts</th>
{% endif %}
</tr>
</thead>
@ -63,11 +72,20 @@
<table class="table table-condensed table-striped tablesorter">
<thead>
<tr>
<th class="col-md-1">Group</th>
<th class="col-md-1">Agenda</th>
<th class="col-md-1">Minutes</th>
<th class="col-md-6">Slides</th>
<th class="col-md-3">Drafts</th>
{% if user and user.is_authenticated and user|managed_groups %}
<th class="col-md-1">Group</th>
<th class="col-md-1">Agenda</th>
<th class="col-md-1">Minutes</th>
<th class="col-md-5">Slides</th>
<th class="col-md-2">Drafts</th>
<th class="col-md-2">&nbsp;</th>
{% else %}
<th class="col-md-1">Group</th>
<th class="col-md-1">Agenda</th>
<th class="col-md-1">Minutes</th>
<th class="col-md-6">Slides</th>
<th class="col-md-3">Drafts</th>
{% endif %}
</tr>
</thead>
@ -88,11 +106,20 @@
<table class="table table-condensed table-striped tablesorter">
<thead>
<tr>
<th class="col-md-1">Group</th>
<th class="col-md-1">Agenda</th>
<th class="col-md-1">Minutes</th>
<th class="col-md-6">Slides</th>
<th class="col-md-3">Drafts</th>
{% if user and user.is_authenticated and user|managed_groups %}
<th class="col-md-1">Group</th>
<th class="col-md-1">Agenda</th>
<th class="col-md-1">Minutes</th>
<th class="col-md-5">Slides</th>
<th class="col-md-2">Drafts</th>
<th class="col-md-2">&nbsp;</th>
{% else %}
<th class="col-md-1">Group</th>
<th class="col-md-1">Agenda</th>
<th class="col-md-1">Minutes</th>
<th class="col-md-6">Slides</th>
<th class="col-md-3">Drafts</th>
{% endif %}
</tr>
</thead>
@ -113,11 +140,20 @@
<table class="table table-condensed table-striped tablesorter">
<thead>
<tr>
<th class="col-md-1">Group</th>
<th class="col-md-1">Agenda</th>
<th class="col-md-1">Minutes</th>
<th class="col-md-6">Slides</th>
<th class="col-md-3">Drafts</th>
{% if user and user.is_authenticated and user|managed_groups %}
<th class="col-md-1">Group</th>
<th class="col-md-1">Agenda</th>
<th class="col-md-1">Minutes</th>
<th class="col-md-5">Slides</th>
<th class="col-md-2">Drafts</th>
<th class="col-md-2">&nbsp;</th>
{% else %}
<th class="col-md-1">Group</th>
<th class="col-md-1">Agenda</th>
<th class="col-md-1">Minutes</th>
<th class="col-md-6">Slides</th>
<th class="col-md-3">Drafts</th>
{% endif %}
</tr>
</thead>
@ -137,11 +173,20 @@
<table class="table table-condensed table-striped tablesorter">
<thead>
<tr>
<th class="col-md-1">Group</th>
<th class="col-md-1">Agenda</th>
<th class="col-md-1">Minutes</th>
<th class="col-md-6">Slides</th>
<th class="col-md-3">Drafts</th>
{% if user and user.is_authenticated and user|managed_groups %}
<th class="col-md-1">Group</th>
<th class="col-md-1">Agenda</th>
<th class="col-md-1">Minutes</th>
<th class="col-md-5">Slides</th>
<th class="col-md-2">Drafts</th>
<th class="col-md-2">&nbsp;</th>
{% else %}
<th class="col-md-1">Group</th>
<th class="col-md-1">Agenda</th>
<th class="col-md-1">Minutes</th>
<th class="col-md-6">Slides</th>
<th class="col-md-3">Drafts</th>
{% endif %}
</tr>
</thead>