moved _grid to _edit_grid and implemented read-only grid version
This commit is contained in:
parent
6a1e59812a
commit
8dc8f5f34a
4 changed files with 75 additions and 3 deletions
27
symposion/templates/schedule/_edit_grid.html
Normal file
27
symposion/templates/schedule/_edit_grid.html
Normal file
|
@ -0,0 +1,27 @@
|
|||
<table class="table table-bordered table-condensed">
|
||||
<tr>
|
||||
<th> </th>
|
||||
{% for room in timetable.rooms %}
|
||||
<th>{{ room.name }}</th>
|
||||
{% endfor %}
|
||||
</tr>
|
||||
{% for row in timetable %}
|
||||
<tr>
|
||||
<td class="time">{{ row.time|date:"h:iA" }}</td>
|
||||
{% for slot in row.slots %}
|
||||
<td class="slot slot-{{ slot.kind.label }}" colspan="{{ slot.colspan }}" rowspan="{{ slow.rowspan }}">
|
||||
{% if slot.kind.label == "talk" %}
|
||||
{% if not slot.content %}
|
||||
<a class="btn btn-mini edit-slot" data-action="{% url schedule_slot_edit schedule.section.slug slot.pk %}" href="#">+</a>
|
||||
{% else %}
|
||||
<div class="title"><a class="edit-slot" data-action="{% url schedule_slot_edit schedule.section.slug slot.pk %}" href="#">{{ slot.content.title }}</a></div>
|
||||
<div class="speaker">{{ slot.content.speaker }}</div>
|
||||
{% endif %}
|
||||
{% else %}
|
||||
{{ slot.kind.label }}
|
||||
{% endif %}
|
||||
</td>
|
||||
{% endfor %}
|
||||
</tr>
|
||||
{% endfor %}
|
||||
</table>
|
|
@ -12,9 +12,8 @@
|
|||
<td class="slot slot-{{ slot.kind.label }}" colspan="{{ slot.colspan }}" rowspan="{{ slow.rowspan }}">
|
||||
{% if slot.kind.label == "talk" %}
|
||||
{% if not slot.content %}
|
||||
<a class="btn btn-mini edit-slot" data-action="{% url schedule_slot_edit schedule.section.slug slot.pk %}" href="#">+</a>
|
||||
{% else %}
|
||||
<div class="title"><a class="edit-slot" data-action="{% url schedule_slot_edit schedule.section.slug slot.pk %}" href="#">{{ slot.content.title }}</a></div>
|
||||
<div class="title"><a class="edit-slot" href="#">{{ slot.content.title }}</a></div>
|
||||
<div class="speaker">{{ slot.content.speaker }}</div>
|
||||
{% endif %}
|
||||
{% else %}
|
||||
|
|
46
symposion/templates/schedule/schedule_detail.html
Normal file
46
symposion/templates/schedule/schedule_detail.html
Normal file
|
@ -0,0 +1,46 @@
|
|||
{% extends "site_base.html" %}
|
||||
|
||||
{% load i18n %}
|
||||
{% load bootstrap_tags %}
|
||||
|
||||
{% block head_title %}Conference Schedule Edit{% endblock %}
|
||||
|
||||
{% block body_class %}full{% endblock %}
|
||||
|
||||
{% block right %}
|
||||
{% endblock %}
|
||||
|
||||
{% block extra_head %}
|
||||
<style>
|
||||
.table td {
|
||||
font-size: 9pt;
|
||||
}
|
||||
.table th, td.slot {
|
||||
text-align: center;
|
||||
vertical-align: middle;
|
||||
}
|
||||
td.time {
|
||||
vertical-align: top;
|
||||
width: 50px;
|
||||
font-size: 8pt;
|
||||
padding-top: 0;
|
||||
}
|
||||
td.slot .title {
|
||||
font-weight: bold;
|
||||
line-height: 10pt;
|
||||
}
|
||||
</style>
|
||||
{% endblock %}
|
||||
|
||||
{% block body_outer %}
|
||||
<div class="row">
|
||||
<div class="span12">
|
||||
<h1>Schedule</h1>
|
||||
|
||||
{% for timetable in days %}
|
||||
<h2>{{ timetable.day.date }}</h2>
|
||||
{% include "schedule/_grid.html" %}
|
||||
{% endfor %}
|
||||
</div>
|
||||
</div>
|
||||
{% endblock %}
|
|
@ -43,7 +43,7 @@
|
|||
|
||||
{% for timetable in days %}
|
||||
<h2>{{ timetable.day.date }}</h2>
|
||||
{% include "schedule/_grid.html" %}
|
||||
{% include "schedule/_edit_grid.html" %}
|
||||
{% endfor %}
|
||||
</div>
|
||||
|
||||
|
|
Loading…
Reference in a new issue