Make table responsive.
This commit is contained in:
parent
0d89adddcd
commit
975775b05f
1 changed files with 65 additions and 59 deletions
|
@ -27,46 +27,49 @@
|
||||||
Liste des livres demandés
|
Liste des livres demandés
|
||||||
<a href="{% url 'add_book' pk=teacher.pk %}" class="btn btn-primary">Ajouter un livre</a>
|
<a href="{% url 'add_book' pk=teacher.pk %}" class="btn btn-primary">Ajouter un livre</a>
|
||||||
</h2>
|
</h2>
|
||||||
<table class="table table-hover table-sm">
|
<div class="table-responsive">
|
||||||
<thead>
|
<table class="table table-hover table-sm">
|
||||||
<tr>
|
<thead>
|
||||||
<th scope="col">Modifier</th>
|
|
||||||
<th scope="col">Classe</th>
|
|
||||||
<th scope="col">Discipline</th>
|
|
||||||
<th scope="col">Titre</th>
|
|
||||||
<th scope="col">Auteurs</th>
|
|
||||||
<th scope="col">Éditeur</th>
|
|
||||||
<th scope="col">Collection</th>
|
|
||||||
<th scope="col">Année de publication</th>
|
|
||||||
<th scope="col">ISBN</th>
|
|
||||||
<th scope="col">Prix</th>
|
|
||||||
<th scope="col">Déjà acheté par l'élève</th>
|
|
||||||
</tr>
|
|
||||||
</thead>
|
|
||||||
<tbody>
|
|
||||||
{% for book in books %}
|
|
||||||
<tr>
|
<tr>
|
||||||
<th scope="row">
|
<th scope="col">Modifier</th>
|
||||||
<a title="Modifier"
|
<th scope="col">Classe</th>
|
||||||
href="{% url 'edit_book' teacher_pk=book.teacher.pk pk=book.pk %}"><i class="fas fa-edit"></i></a>
|
<th scope="col">Discipline</th>
|
||||||
</th>
|
<th scope="col">Titre</th>
|
||||||
<td>{{ book.level }}</td>
|
<th scope="col">Auteurs</th>
|
||||||
<td>{{ book.field }}</td>
|
<th scope="col">Éditeur</th>
|
||||||
<td>{{ book.title }}</td>
|
<th scope="col">Collection</th>
|
||||||
<td>{{ book.authors }}</td>
|
<th scope="col">Année de publication</th>
|
||||||
<td>{{ book.editor }}</td>
|
<th scope="col">ISBN</th>
|
||||||
<td>{{ book.collection }}</td>
|
<th scope="col">Prix</th>
|
||||||
<td>{{ book.publication_year }}</td>
|
<th scope="col">Déjà acheté par l'élève</th>
|
||||||
<td>{{ book.isbn }}</td>
|
|
||||||
<td>{{ book.price }}€</td>
|
|
||||||
<td>
|
|
||||||
<i class="fas fa-{% if book.previously_acquired %}check-circle{% else %}ban{% endif %}"></i>
|
|
||||||
{{ book.previously_acquired_text }}
|
|
||||||
</td>
|
|
||||||
</tr>
|
</tr>
|
||||||
{% endfor %}
|
</thead>
|
||||||
</tbody>
|
<tbody>
|
||||||
</table>
|
{% for book in books %}
|
||||||
|
<tr>
|
||||||
|
<th scope="row">
|
||||||
|
<a title="Modifier"
|
||||||
|
href="{% url 'edit_book' teacher_pk=book.teacher.pk pk=book.pk %}"><i
|
||||||
|
class="fas fa-edit"></i></a>
|
||||||
|
</th>
|
||||||
|
<td>{{ book.level }}</td>
|
||||||
|
<td>{{ book.field }}</td>
|
||||||
|
<td>{{ book.title }}</td>
|
||||||
|
<td>{{ book.authors }}</td>
|
||||||
|
<td>{{ book.editor }}</td>
|
||||||
|
<td>{{ book.collection }}</td>
|
||||||
|
<td>{{ book.publication_year }}</td>
|
||||||
|
<td>{{ book.isbn }}</td>
|
||||||
|
<td>{{ book.price }}€</td>
|
||||||
|
<td>
|
||||||
|
<i class="fas fa-{% if book.previously_acquired %}check-circle{% else %}ban{% endif %}"></i>
|
||||||
|
{{ book.previously_acquired_text }}
|
||||||
|
</td>
|
||||||
|
</tr>
|
||||||
|
{% endfor %}
|
||||||
|
</tbody>
|
||||||
|
</table>
|
||||||
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="row">
|
<div class="row">
|
||||||
|
@ -75,29 +78,32 @@
|
||||||
Liste des fournitures demandées
|
Liste des fournitures demandées
|
||||||
<a href="{% url 'add_supplies' pk=teacher.pk %}" class="btn btn-primary">Ajouter des fournitures</a>
|
<a href="{% url 'add_supplies' pk=teacher.pk %}" class="btn btn-primary">Ajouter des fournitures</a>
|
||||||
</h2>
|
</h2>
|
||||||
<table class="table table-hover table-sm">
|
<div class="table-responsive">
|
||||||
<thead>
|
<table class="table table-hover table-sm">
|
||||||
<tr>
|
<thead>
|
||||||
<th scope="col">Modifier</th>
|
|
||||||
<th scope="col">Classe</th>
|
|
||||||
<th scope="col">Disciplines</th>
|
|
||||||
<th scope="col">Liste de fournitures</th>
|
|
||||||
</tr>
|
|
||||||
</thead>
|
|
||||||
<tbody>
|
|
||||||
{% for supply in supplies %}
|
|
||||||
<tr>
|
<tr>
|
||||||
<th scope="row">
|
<th scope="col">Modifier</th>
|
||||||
<a title="Modifier"
|
<th scope="col">Classe</th>
|
||||||
href="{% url 'edit_supplies' teacher_pk=supply.teacher.pk pk=supply.pk %}"><i class="fas fa-edit"></i></a>
|
<th scope="col">Disciplines</th>
|
||||||
</th>
|
<th scope="col">Liste de fournitures</th>
|
||||||
<td>{{ supply.level }}</td>
|
|
||||||
<td>{{ supply.fields }}</td>
|
|
||||||
<td>{{ supply.supplies|linebreaksbr }}</td>
|
|
||||||
</tr>
|
</tr>
|
||||||
{% endfor %}
|
</thead>
|
||||||
</tbody>
|
<tbody>
|
||||||
</table>
|
{% for supply in supplies %}
|
||||||
|
<tr>
|
||||||
|
<th scope="row">
|
||||||
|
<a title="Modifier"
|
||||||
|
href="{% url 'edit_supplies' teacher_pk=supply.teacher.pk pk=supply.pk %}"><i
|
||||||
|
class="fas fa-edit"></i></a>
|
||||||
|
</th>
|
||||||
|
<td>{{ supply.level }}</td>
|
||||||
|
<td>{{ supply.fields }}</td>
|
||||||
|
<td>{{ supply.supplies|linebreaksbr }}</td>
|
||||||
|
</tr>
|
||||||
|
{% endfor %}
|
||||||
|
</tbody>
|
||||||
|
</table>
|
||||||
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
{% endblock %}
|
{% endblock %}
|
Loading…
Reference in a new issue