improved css
This commit is contained in:
parent
7f1564dd0d
commit
9c4cb77d35
7 changed files with 149 additions and 98 deletions
|
@ -543,7 +543,7 @@ class TeachingSession(models.Model, ModelPermissionHelper):
|
||||||
"""
|
"""
|
||||||
|
|
||||||
return Absence.objects.filter(
|
return Absence.objects.filter(
|
||||||
student__in=self.group.students,
|
student__in=self.group.students.all(),
|
||||||
start__lte=self.start, end__gte=self.end
|
start__lte=self.start, end__gte=self.end
|
||||||
).distinct()
|
).distinct()
|
||||||
|
|
||||||
|
|
|
@ -1,15 +1,47 @@
|
||||||
/* tweaks */
|
|
||||||
body {
|
|
||||||
margin: 0;
|
|
||||||
}
|
|
||||||
|
|
||||||
/* font */
|
/* font */
|
||||||
* {
|
* {
|
||||||
font-family: "Century Gothic", sans-serif;
|
font-family: "Century Gothic", sans-serif;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/* color-scheme */
|
||||||
|
@media (prefers-color-scheme: light) {
|
||||||
|
:root {
|
||||||
|
--primary: #00345F;
|
||||||
|
--secondary: #EF800A;
|
||||||
|
|
||||||
|
--foreground: #1B1B1B;
|
||||||
|
--background: #FFFFFF;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
@media (prefers-color-scheme: dark) {
|
||||||
|
:root {
|
||||||
|
--primary: #00549F;
|
||||||
|
--secondary: #EF800A;
|
||||||
|
|
||||||
|
--foreground: #FFFFFF;
|
||||||
|
--background: #1B1B1B;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
/* links */
|
/* links */
|
||||||
*:link, *:visited {
|
*:link, *:visited {
|
||||||
color: blue; /* TODO: should be palette based color */
|
color: var(--primary);
|
||||||
text-decoration: none;
|
text-decoration: none;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
*:link:hover, *:visited:hover {
|
||||||
|
color: var(--secondary);
|
||||||
|
}
|
||||||
|
|
||||||
|
/* table */
|
||||||
|
table, tr, th, td {
|
||||||
|
border-color: var(--foreground) !important;
|
||||||
|
}
|
||||||
|
|
||||||
|
/* tweaks */
|
||||||
|
body {
|
||||||
|
margin: 0;
|
||||||
|
color: var(--foreground);
|
||||||
|
background-color: var(--background);
|
||||||
|
}
|
|
@ -1,39 +1,34 @@
|
||||||
#department-informations {
|
#table-informations {
|
||||||
border-collapse: collapse;
|
border-collapse: collapse;
|
||||||
border: 2px solid black;
|
border: 2px solid black;
|
||||||
margin: 5% auto;
|
margin: 5% auto;
|
||||||
}
|
}
|
||||||
|
|
||||||
#department-informations th {
|
#table-informations th {
|
||||||
text-align: right;
|
text-align: right;
|
||||||
border: 1px solid black;
|
border: 1px solid black;
|
||||||
padding: 4px;
|
padding: 4px;
|
||||||
}
|
}
|
||||||
|
|
||||||
#department-informations td {
|
#table-informations td {
|
||||||
text-align: left;
|
text-align: left;
|
||||||
border: 1px solid black;
|
border: 1px solid black;
|
||||||
padding: 4px;
|
padding: 4px;
|
||||||
}
|
}
|
||||||
|
|
||||||
#department-relations {
|
#table-relations {
|
||||||
display: flex;
|
display: flex;
|
||||||
width: 60%;
|
width: 60%;
|
||||||
margin: auto;
|
margin: auto;
|
||||||
}
|
}
|
||||||
|
|
||||||
.department-relation {
|
.table-relation {
|
||||||
border-collapse: collapse;
|
border-collapse: collapse;
|
||||||
border: 2px solid black;
|
border: 2px solid black;
|
||||||
margin: 0 auto auto auto;
|
margin: 0 auto auto auto;
|
||||||
}
|
}
|
||||||
|
|
||||||
.department-relation th {
|
.table-relation th, .table-relation td {
|
||||||
border: 2px solid black;
|
|
||||||
padding: 4px;
|
|
||||||
}
|
|
||||||
|
|
||||||
.department-relation td {
|
|
||||||
border: 2px solid black;
|
border: 2px solid black;
|
||||||
padding: 4px;
|
padding: 4px;
|
||||||
}
|
}
|
|
@ -12,14 +12,14 @@
|
||||||
|
|
||||||
{% block style %}
|
{% block style %}
|
||||||
{{ block.super }}
|
{{ block.super }}
|
||||||
<link rel="stylesheet" href="{% static "Palto/css/department_view.css" %}" />
|
<link rel="stylesheet" href="{% static "Palto/css/table_view.css" %}" />
|
||||||
{% endblock %}
|
{% endblock %}
|
||||||
|
|
||||||
{% block body %}
|
{% block body %}
|
||||||
{{ block.super }}
|
{{ block.super }}
|
||||||
|
|
||||||
{# department's information #}
|
{# department's information #}
|
||||||
<table id="department-informations">
|
<table id="table-informations">
|
||||||
<tr>
|
<tr>
|
||||||
<th>Identifiant</th>
|
<th>Identifiant</th>
|
||||||
<td>{{ department.id }}</td>
|
<td>{{ department.id }}</td>
|
||||||
|
@ -42,9 +42,9 @@
|
||||||
</tr>
|
</tr>
|
||||||
</table>
|
</table>
|
||||||
|
|
||||||
<div id="department-relations">
|
<div id="table-relations">
|
||||||
{# department's managers #}
|
{# department's managers #}
|
||||||
<table class="department-relation">
|
<table class="table-relation">
|
||||||
<thead>
|
<thead>
|
||||||
<tr>
|
<tr>
|
||||||
<th>Responsables</th>
|
<th>Responsables</th>
|
||||||
|
@ -60,7 +60,7 @@
|
||||||
</table>
|
</table>
|
||||||
|
|
||||||
{# department's teachers #}
|
{# department's teachers #}
|
||||||
<table class="department-relation">
|
<table class="table-relation">
|
||||||
<thead>
|
<thead>
|
||||||
<tr>
|
<tr>
|
||||||
<th>Enseignants</th>
|
<th>Enseignants</th>
|
||||||
|
|
|
@ -1,4 +1,5 @@
|
||||||
{% extends "Palto/base/base-features.html" %}
|
{% extends "Palto/base/base-features.html" %}
|
||||||
|
{% load static %}
|
||||||
|
|
||||||
{% block page-title %}
|
{% block page-title %}
|
||||||
Groupe Étudiant {{ group.name }}
|
Groupe Étudiant {{ group.name }}
|
||||||
|
@ -8,11 +9,16 @@
|
||||||
Groupe Étudiant {{ group.name }}
|
Groupe Étudiant {{ group.name }}
|
||||||
{% endblock %}
|
{% endblock %}
|
||||||
|
|
||||||
|
{% block style %}
|
||||||
|
{{ block.super }}
|
||||||
|
<link rel="stylesheet" href="{% static "Palto/css/table_view.css" %}" />
|
||||||
|
{% endblock %}
|
||||||
|
|
||||||
{% block body %}
|
{% block body %}
|
||||||
{{ block.super }}
|
{{ block.super }}
|
||||||
|
|
||||||
{# group's information #}
|
{# group's information #}
|
||||||
<table>
|
<table id="table-informations">
|
||||||
<tr>
|
<tr>
|
||||||
<th>Identifiant</th>
|
<th>Identifiant</th>
|
||||||
<td>{{ group.id }}</td>
|
<td>{{ group.id }}</td>
|
||||||
|
@ -31,8 +37,9 @@
|
||||||
</tr>
|
</tr>
|
||||||
</table>
|
</table>
|
||||||
|
|
||||||
|
<div id="table-relations">
|
||||||
{# group's students information #}
|
{# group's students information #}
|
||||||
<table>
|
<table class="table-relation">
|
||||||
<thead>
|
<thead>
|
||||||
<tr>
|
<tr>
|
||||||
<th>Étudiants</th>
|
<th>Étudiants</th>
|
||||||
|
@ -46,4 +53,5 @@
|
||||||
{% endfor %}
|
{% endfor %}
|
||||||
</tbody>
|
</tbody>
|
||||||
</table>
|
</table>
|
||||||
|
</div>
|
||||||
{% endblock %}
|
{% endblock %}
|
||||||
|
|
|
@ -1,5 +1,6 @@
|
||||||
{% extends "Palto/base/base-features.html" %}
|
{% extends "Palto/base/base-features.html" %}
|
||||||
{% load dict_tags %}
|
{% load dict_tags %}
|
||||||
|
{% load static %}
|
||||||
|
|
||||||
{% block page-title %}
|
{% block page-title %}
|
||||||
Session de {{ session.unit.name }}
|
Session de {{ session.unit.name }}
|
||||||
|
@ -9,11 +10,16 @@
|
||||||
Session de {{ session.unit.name }}
|
Session de {{ session.unit.name }}
|
||||||
{% endblock %}
|
{% endblock %}
|
||||||
|
|
||||||
|
{% block style %}
|
||||||
|
{{ block.super }}
|
||||||
|
<link rel="stylesheet" href="{% static "Palto/css/table_view.css" %}" />
|
||||||
|
{% endblock %}
|
||||||
|
|
||||||
{% block body %}
|
{% block body %}
|
||||||
{{ block.super }}
|
{{ block.super }}
|
||||||
|
|
||||||
{# session's information #}
|
{# session's information #}
|
||||||
<table>
|
<table id="table-informations">
|
||||||
<tr>
|
<tr>
|
||||||
<th>Identifiant</th>
|
<th>Identifiant</th>
|
||||||
<td>{{ session.id }}</td>
|
<td>{{ session.id }}</td>
|
||||||
|
@ -40,8 +46,9 @@
|
||||||
</tr>
|
</tr>
|
||||||
</table>
|
</table>
|
||||||
|
|
||||||
|
<div id="table-relations">
|
||||||
{# session's students information #}
|
{# session's students information #}
|
||||||
<table>
|
<table class="table-relation">
|
||||||
<thead>
|
<thead>
|
||||||
<tr>
|
<tr>
|
||||||
<th>Elève</th>
|
<th>Elève</th>
|
||||||
|
@ -71,6 +78,7 @@
|
||||||
{% endfor %}
|
{% endfor %}
|
||||||
</tbody>
|
</tbody>
|
||||||
</table>
|
</table>
|
||||||
|
</div>
|
||||||
|
|
||||||
{# TODO(Raphaël): export boutton #}
|
{# TODO(Raphaël): export boutton #}
|
||||||
{% endblock %}
|
{% endblock %}
|
||||||
|
|
|
@ -1,5 +1,6 @@
|
||||||
{% extends "Palto/base/base-features.html" %}
|
{% extends "Palto/base/base-features.html" %}
|
||||||
{% load dict_tags %}
|
{% load dict_tags %}
|
||||||
|
{% load static %}
|
||||||
|
|
||||||
{% block page-title %}
|
{% block page-title %}
|
||||||
Unité d'Enseignement de {{ unit.name }}
|
Unité d'Enseignement de {{ unit.name }}
|
||||||
|
@ -9,11 +10,16 @@
|
||||||
Unité d'Enseignement de {{ unit.name }}
|
Unité d'Enseignement de {{ unit.name }}
|
||||||
{% endblock %}
|
{% endblock %}
|
||||||
|
|
||||||
|
{% block style %}
|
||||||
|
{{ block.super }}
|
||||||
|
<link rel="stylesheet" href="{% static "Palto/css/table_view.css" %}" />
|
||||||
|
{% endblock %}
|
||||||
|
|
||||||
{% block body %}
|
{% block body %}
|
||||||
{{ block.super }}
|
{{ block.super }}
|
||||||
|
|
||||||
{# unit's information #}
|
{# unit's information #}
|
||||||
<table>
|
<table id="table-informations">
|
||||||
<tr>
|
<tr>
|
||||||
<th>Identifiant</th>
|
<th>Identifiant</th>
|
||||||
<td>{{ unit.id }}</td>
|
<td>{{ unit.id }}</td>
|
||||||
|
@ -24,7 +30,7 @@
|
||||||
</tr>
|
</tr>
|
||||||
<tr>
|
<tr>
|
||||||
<th>Département</th>
|
<th>Département</th>
|
||||||
<td href="{% url "Palto:department_view" unit.department.id %}">{{ unit.department.name }}</td>
|
<td><a href="{% url "Palto:department_view" unit.department.id %}">{{ unit.department.name }}</a></td>
|
||||||
</tr>
|
</tr>
|
||||||
<tr>
|
<tr>
|
||||||
<th>Mail</th>
|
<th>Mail</th>
|
||||||
|
@ -36,8 +42,9 @@
|
||||||
</tr>
|
</tr>
|
||||||
</table>
|
</table>
|
||||||
|
|
||||||
|
<div id="table-relations">
|
||||||
{# unit's managers #}
|
{# unit's managers #}
|
||||||
<table>
|
<table class="table-relation">
|
||||||
<thead>
|
<thead>
|
||||||
<tr>
|
<tr>
|
||||||
<th>Responsables</th>
|
<th>Responsables</th>
|
||||||
|
@ -53,7 +60,7 @@
|
||||||
</table>
|
</table>
|
||||||
|
|
||||||
{# unit's teachers #}
|
{# unit's teachers #}
|
||||||
<table>
|
<table class="table-relation">
|
||||||
<thead>
|
<thead>
|
||||||
<tr>
|
<tr>
|
||||||
<th>Enseignants</th>
|
<th>Enseignants</th>
|
||||||
|
@ -67,4 +74,5 @@
|
||||||
{% endfor %}
|
{% endfor %}
|
||||||
</tbody>
|
</tbody>
|
||||||
</table>
|
</table>
|
||||||
|
</div>
|
||||||
{% endblock %}
|
{% endblock %}
|
||||||
|
|
Loading…
Reference in a new issue