Update opolka/ScoDoc from ScoDoc/ScoDoc #2

Merged
opolka merged 1272 commits from ScoDoc/ScoDoc:master into master 2024-05-27 09:11:04 +02:00
Showing only changes of commit a81f8e9679 - Show all commits

View File

@ -105,12 +105,13 @@ class RowAssi(tb.Row):
stats = self._get_etud_stats(etud)
for key, value in stats.items():
self.add_cell(key, value[0], f"{value[1] - value[2]}", "assi_stats")
self.add_cell(
key + "_justi",
value[0] + " Justifiées",
f"{value[2]}",
"assi_stats",
)
if key != "present":
self.add_cell(
key + "_justi",
value[0] + " Justifiées",
f"{value[2]}",
"assi_stats",
)
compte_justificatifs = scass.filter_by_date(
etud.justificatifs, Justificatif, self.dates[0], self.dates[1]
@ -128,6 +129,7 @@ class RowAssi(tb.Row):
)
def _get_etud_stats(self, etud: Identite) -> dict[str, list[str, float, float]]:
# XXX TODO @iziram commentaire sur la fonction et la var. retour
retour: dict[str, tuple[str, float, float]] = {
"present": ["Présences", 0.0, 0.0],
"retard": ["Retards", 0.0, 0.0],