mirror of
https://github.com/nottinghamtec/PyRIGS.git
synced 2026-01-20 06:52:15 +00:00
Optimised displaying of values in autocomplete boxes on the event form (removed extra AJAX request) Highlighted missing MIC better due to bootstrap changes
117 lines
5.3 KiB
HTML
117 lines
5.3 KiB
HTML
{% extends 'base.html' %}
|
|
|
|
{% block title %}Rigboard{% endblock %}
|
|
|
|
{% block content %}
|
|
<div class="row">
|
|
<div class="col-sm-12">
|
|
<div class="row">
|
|
<div class="col-sm-10">
|
|
<h3>Rigboard</h3>
|
|
</div>
|
|
<div class="col-sm-2">
|
|
<a href="{% url 'event_create' %}" class="btn btn-default pull-right">New <span
|
|
class="glyphicon glyphicon-plus"></span></a>
|
|
</div>
|
|
{% comment %}
|
|
{# Bring search back at a later date #}
|
|
<div class="col-sm-3 col-sm-offset-9">
|
|
<form class="form form-horizontal col-sm-12">
|
|
<div class="form-group">
|
|
<input type="search" name="q" placeholder="Search" value="{{ request.GET.q }}"
|
|
class="form-control"/>
|
|
</div>
|
|
</form>
|
|
</div>
|
|
{% endcomment %}
|
|
</div>
|
|
{# .row #}
|
|
|
|
<div class="table-responsive">
|
|
<table class="table">
|
|
<thead>
|
|
<td class="hidden-xs">#</td>
|
|
<td>Event Date</td>
|
|
<td>Event Details</td>
|
|
<td>Event Timings</td>
|
|
<td>MIC</td>
|
|
</thead>
|
|
<tbody>
|
|
{% for event in events %}
|
|
<tr class="
|
|
{% if event.cancelled %}
|
|
active
|
|
{% elif event.confirmed and event.mic or not event.is_rig %}
|
|
{# interpreated as (booked and mic) or is non rig #}
|
|
success
|
|
{% elif event.mic %}
|
|
warning
|
|
{% else %}
|
|
danger text-danger
|
|
{% endif %}
|
|
">
|
|
<td class="hidden-xs">{{ event.pk }}</td>
|
|
<td>
|
|
<div><strong>{{ event.start_date|date:"SHORT_DATE_FORMAT" }}</strong></div>
|
|
{% if event.end_date and event.end_date != event.start_date %}
|
|
<div><strong>{{ event.end_date|date:"SHORT_DATE_FORMAT" }}</strong></div>
|
|
{% endif %}
|
|
</td>
|
|
<td>
|
|
<h4>
|
|
<a href="{% url 'event_detail' event.pk %}">{{ event.name }}</a>
|
|
{% if event.venue %}
|
|
<small>at {{ event.venue }}</small>
|
|
{% endif %}
|
|
</h4>
|
|
{% if event.is_rig %}
|
|
<h5>
|
|
{{ event.person.name }}
|
|
{% if event.organisation %}
|
|
for {{ event.organisation.name }}
|
|
{% endif %}
|
|
</h5>
|
|
{% endif %}
|
|
{% if not event.cancelled and event.description %}
|
|
<div>
|
|
{{ event.description|linebreaksbr }}
|
|
</div>
|
|
{% endif %}
|
|
</td>
|
|
<td>
|
|
<dl class="dl-horizontal">
|
|
{% if event.meet_at %}
|
|
<dt>Crew meet</dt>
|
|
<dd>{{ event.meet_at|date:"H:i" }}<br/>{{ event.meet_at|date:"(Y-m-d)" }}</dd>
|
|
{% endif %}
|
|
{% if event.start_time %}
|
|
<dt>Event starts</dt>
|
|
<dd>
|
|
{{ event.start_time|date:"H:i" }}<br/>
|
|
{{ event.start_date|date:"(Y-m-d)" }}
|
|
</dd>
|
|
{% endif %}
|
|
{% if event.end_time and event.start_time != event.end_time %}
|
|
<dt>Event ends</dt>
|
|
<dd>
|
|
{{ event.end_time|date:"H:i" }}<br/>
|
|
{{ event.end_date|date:"(Y-m-d)" }}
|
|
</dd>
|
|
{% endif %}
|
|
</dl>
|
|
</td>
|
|
<td class="text-center">
|
|
{% if event.mic or not event.is_rig %}
|
|
{{ event.mic.initials }}
|
|
{% else %}
|
|
<span class="glyphicon glyphicon-exclamation-sign"></span>
|
|
{% endif %}
|
|
</td>
|
|
</tr>
|
|
{% endfor %}
|
|
</tbody>
|
|
</table>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
{% endblock %} |