Files
PyRIGS/RIGS/templates/event_table_mobile.html

42 lines
1.5 KiB
HTML
Raw Blame History

This file contains invisible Unicode characters

This file contains invisible Unicode characters that are indistinguishable to humans but may be processed differently by a computer. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

<div class="card">
{% for event in events %}
<div class="card-header {% if event.cancelled %}
text-muted bg-secondary
{% elif event.authorised and event.risk_assessment_edit_url and event.mic %}
bg-success
{% elif not event.is_rig %}
bg-info
{% else %}
bg-warning
{% endif %}
">
<a href="{% url 'event_detail' event.pk %}">{{ event.pk }} | {{ event.name }}</a>
{% if event.dry_hire %}
<span class="badge badge-pill badge-secondary">Dry Hire</span>
{% endif %}
</div>
<div class="card-body">
{% include 'partials/event_status.html' %}
<h6 class="pt-2"><strong>{{ event.start_date|date:"D d/m/Y" }}</strong>
{% if event.end_date and event.end_date != event.start_date %}
<strong> {{ event.end_date|date:"D d/m/Y" }}</strong></h4>
{% else %}
</h6>
{% endif %}
<ul class="list-group list-group-flush pb-3">
<li class="list-group-item">Venue: {{ event.venue }}</li>
<li class="list-group-item">Client: {{ event.person }}</li>
<li class="list-group-item">Organisation: {{ event.organisation }}</li>
</ul>
{% if not event.cancelled and event.description %}
<p>{{ event.description|linebreaksbr }}</p>
{% endif %}
</div>
<div class="card-footer">MIC: {% if event.mic %}<p>{{ event.mic.initials }}</p>{% elif event.is_rig %}<i class="fas fa-exclamation"></i>{% endif %}</div>
{% empty %}
<div class="card-body bg-warning">
<p>No events found</p>
</div>
{% endfor %}
</div>