Skip to content
Snippets Groups Projects
Commit 5d556592 authored by Piotr Matyjaszyk's avatar Piotr Matyjaszyk
Browse files

added a forgotten index file

parent be50c3a6
No related branches found
No related tags found
No related merge requests found
{% extends "_base.html" %}
{% load static %}
{% block styles %}
{{ block.super }}
<!-- DataTables -->
<link rel="stylesheet" href="{% static 'AdminLTE/plugins/datatables/dataTables.bootstrap.css' %}">
{% endblock styles %}
{% block page_title %}'eqdef'{% endblock page_title %}
{% block page_header %}Equipment definitions{% endblock page_header %}
{% block page_description %}{% endblock page_description %}
{% block breadcrumb %}
<li><a href="#"><i class="fa fa-dashboard"></i> Dashboard</a></li>
<li class="active">Equipment definitions</li>
{% endblock breadcrumb %}
{% block maincontent %}
<div>
<a class="btn btn-app">
<i class="fa fa-plus"></i> Add new equipment type
</a>
</div>
<div class="box-body">
{% if equipment_list %}
<table id="table" class="table table-bordered table-striped">
<thead>
<tr>
<th>No.</th>
<th>Name</th>
<th>Is fixed?</th>
<th>Edit</th>
<th>Delete</th>
</tr>
</thead>
<tbody>
{% for equip in equipment_list %}
<tr>
<td>{{ forloop.counter }}</td>
<td>{{ equip.name }}</td>
<td>
{% if equip.isFixed %}<button type="button" class="btn btn-block btn-danger">YES</button>
{% else %}<button type="button" class="btn btn-block btn-success">NO</button>
{% endif %}
</td>
<td><button type="button" class="btn btn-block btn-default">Edit</button></td>
<td><button type="button" class="btn btn-block btn-default">Delete</button></td>
</tr>
{% endfor %}
</tbody>
</table>
{% else %}
<p>No equipment found.</p>
{% endif %}
</div>
{% endblock maincontent %}
{% block scripts %}
{{ block.super }}
<script src="{% static 'AdminLTE/plugins/datatables/jquery.dataTables.min.js' %}"></script>
<script src="{% static 'AdminLTE/plugins/datatables/dataTables.bootstrap.min.js' %}"></script>
<script>
$(function () {
$('#table').DataTable({
"paging": true,
"lengthChange": false,
"searching": false,
"ordering": true,
"info": true,
"autoWidth": false
});
});
</script>
{% endblock scripts %}
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment