53 lines
2.2 KiB
HTML
53 lines
2.2 KiB
HTML
|
{% extends 'base.html' %}
|
||
|
{% load static %}
|
||
|
|
||
|
{% block title %}
|
||
|
Facilities | BackOffice | {{ block.super }}
|
||
|
{% endblock %}
|
||
|
|
||
|
{% block content %}
|
||
|
<div class="panel panel-default">
|
||
|
<div class="panel-heading">
|
||
|
<h3 class="panel-title">Facilities - BackOffice</h3>
|
||
|
</div>
|
||
|
<div class="panel-body">
|
||
|
<p class="lead">The following {{ facility_list.count }} facilities are defined for {{ camp.title }}</p>
|
||
|
<p>
|
||
|
<a href="{% url 'backoffice:facility_create' camp_slug=camp.slug %}" class="btn btn-success"><i class="fas fa-plus"></i> Create Facility</a>
|
||
|
<a class="btn btn-default" href="{% url 'backoffice:index' camp_slug=camp.slug %}"><i class="fas fa-undo"></i> Backoffice</a>
|
||
|
</p>
|
||
|
<table class="table datatable">
|
||
|
<thead>
|
||
|
<tr>
|
||
|
<th>Name</th>
|
||
|
<th>Type</th>
|
||
|
<th>Team</th>
|
||
|
<th>Description</th>
|
||
|
<th>Location</th>
|
||
|
<th class="text-center">Feedback / Unhandled</th>
|
||
|
<th>Actions</th>
|
||
|
</tr>
|
||
|
</thead>
|
||
|
<tbody>
|
||
|
{% for facility in facility_list %}
|
||
|
<tr>
|
||
|
<td>{{ facility.name }}</td>
|
||
|
<td><i class="fas fa-{{ facility.facility_type.icon }} fa-2x fa-fw"></i> {{ facility.facility_type.name }}</td>
|
||
|
<td>{{ facility.team.name }} Team</td>
|
||
|
<td>{{ facility.description|default:"N/A" }}</td>
|
||
|
<td>{{ facility.location }}</td>
|
||
|
<td class="text-center"><span class="badge">{{ facility.feedbacks.count }}</span> / <span class="badge">{{ facility.unhandled_feedbacks.count }}</span></td>
|
||
|
<td>
|
||
|
<div class="btn-group btn-group-vertical">
|
||
|
<a href="{% url "backoffice:facility_detail" camp_slug=camp.slug facility_uuid=facility.pk %}" class="btn btn-primary"><i class="fas fa-search"></i> Details</a>
|
||
|
<a href="{% url "backoffice:facility_update" camp_slug=camp.slug facility_uuid=facility.pk %}" class="btn btn-primary"><i class="fas fa-edit"></i> Update</a>
|
||
|
<a href="{% url "backoffice:facility_delete" camp_slug=camp.slug facility_uuid=facility.pk %}" class="btn btn-danger"><i class="fas fa-times"></i> Delete</a>
|
||
|
</div>
|
||
|
</td>
|
||
|
</tr>
|
||
|
{% endfor %}
|
||
|
</table>
|
||
|
</div>
|
||
|
</div>
|
||
|
{% endblock %}
|