104 lines
2.6 KiB
HTML
104 lines
2.6 KiB
HTML
{% extends "base.html" %}
|
|
|
|
{% load static %}
|
|
{% load extras %}
|
|
|
|
{% block title %}Colloscope{% endblock title %}
|
|
|
|
{% block head %}
|
|
<link href="{% static 'table.css' %}" rel="stylesheet" type="text/css">
|
|
{% endblock head %}
|
|
|
|
{% block header %}
|
|
<h1>Colloscope</h1>
|
|
{% endblock header %}
|
|
|
|
|
|
{% block main %}
|
|
|
|
<p>
|
|
Lycée : {{ periode.classe.lycee.libelle }}. Classe : {{ periode.classe.libelle }}. <a href="dashboard.html">Retour au tableau de bord</a>
|
|
</p>
|
|
|
|
<h2>Colloscope : {{ periode.libelle }}</h2>
|
|
|
|
<form method="get" action="{% url "colloscope.table" %}">
|
|
Changer de période :
|
|
<select name="periode" id="periode">
|
|
{% for p in periode.classe.periode_set.all %}
|
|
{% if p.id == periode.id %}
|
|
<option value="{{ p.id }}" selected>{{ p }}</option>
|
|
{% else %}
|
|
<option value="{{ p.id }}" selected>{{ p }}</option>
|
|
{% endif %}
|
|
{% endfor %}
|
|
</select>
|
|
<button type="submit">Valider</button>
|
|
</form>
|
|
|
|
{% if request.GET.periode %}
|
|
<a href="export.pdf?periode={{ request.GET.periode }}" target="_blank">Exporter le colloscope</a>
|
|
{% else %}
|
|
<a href="export.pdf" target="_blank">Exporter le colloscope</a>
|
|
{% endif %}
|
|
|
|
<div class="table-wrapper">
|
|
<table>
|
|
|
|
<colgroup>
|
|
<col>
|
|
<col>
|
|
<col>
|
|
<col>
|
|
<col>
|
|
</colgroup>
|
|
<colgroup>
|
|
{% for _ in semaines %}
|
|
<col>
|
|
{% endfor %}
|
|
</colgroup>
|
|
|
|
<tr>
|
|
<th rowspan=2>Matière</th>
|
|
<th rowspan=2>Jour</th>
|
|
<th rowspan=2>Heure</th>
|
|
<th rowspan=2>Colleur</th>
|
|
<th rowspan=2>Salle</th>
|
|
{% for n in semaines %}
|
|
<th>{{ n }}</th>
|
|
{% endfor %}
|
|
</tr>
|
|
|
|
<tr>
|
|
{% for lundi in lundis %}
|
|
<th>{{ lundi | strftime:"%d/%m/%y" }}</th>
|
|
{% endfor %}
|
|
</tr>
|
|
|
|
|
|
{% for c, rs in rotations %}
|
|
<tr>
|
|
<td>{{ c.matiere.libelle }}</td>
|
|
<td>{{ jours | getitem:c.jour }}</td>
|
|
<td>{{ c.heure | strftime:"%H:%M" }}</td>
|
|
<td>{{ c.colleur }}</td>
|
|
<td>{{ c.salle }}</td>
|
|
|
|
{% for sem, exists, r, est_modifiee, groupes in rs %}
|
|
{% if exists %}
|
|
{% if est_modifiee %}
|
|
<td class="modif">{{ groupes | join:"," }}</td>
|
|
{% else %}
|
|
<td>{{ groupes | join:"," }}</td>
|
|
{% endif %}
|
|
{% else %}
|
|
<td></td>
|
|
{% endif %}
|
|
{% endfor %}
|
|
</tr>
|
|
{% endfor %}
|
|
|
|
</table>
|
|
</div>
|
|
{% endblock main %}
|