From 3fe5595cae80c5fc7d1cd5b89c9caa6fa7656005 Mon Sep 17 00:00:00 2001 From: Emmanuel Viennet Date: Sun, 3 Sep 2023 21:00:20 +0200 Subject: [PATCH] =?UTF-8?q?Petites=20am=C3=A9liorations=20du=20bul=20BUT?= =?UTF-8?q?=20court=20(suggestions=20de=20LGS)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- app/but/bulletin_but_court_pdf.py | 20 +++++++++++--------- app/templates/but/bulletin_court_page.j2 | 20 +++++++------------- sco_version.py | 2 +- 3 files changed, 19 insertions(+), 23 deletions(-) diff --git a/app/but/bulletin_but_court_pdf.py b/app/but/bulletin_but_court_pdf.py index 1887efd24..9642de833 100644 --- a/app/but/bulletin_but_court_pdf.py +++ b/app/but/bulletin_but_court_pdf.py @@ -170,7 +170,7 @@ class BulletinGeneratorBUTCourt(BulletinGeneratorStandard): self.width_page_avail = 185 * mm # largeur utilisable # Géométrie tableaux self.width_col_ue = 18 * mm - self.width_col_ue_titres = 15 * mm + self.width_col_ue_titres = 16.5 * mm # Modules self.width_col_code = self.width_col_ue # Niveaux @@ -259,19 +259,21 @@ class BulletinGeneratorBUTCourt(BulletinGeneratorStandard): [""] + self.ues_acronyms, ["Moyenne"] + [bul["ues"][ue]["moyenne"]["value"] for ue in self.ues_acronyms], - ["Bonus"] + ["dont bonus"] + [ bul["ues"][ue]["bonus"] if bul["ues"][ue]["bonus"] != "00.00" else "" for ue in self.ues_acronyms ], - ["Malus"] + ["et malus"] + [ bul["ues"][ue]["malus"] if bul["ues"][ue]["malus"] != "00.00" else "" for ue in self.ues_acronyms ], - ["Rang"] + [bul["ues"][ue]["moyenne"]["rang"] for ue in self.ues_acronyms], - ["Effectif"] - + [bul["ues"][ue]["moyenne"]["total"] for ue in self.ues_acronyms], + ["Rang"] + + [ + f'{bul["ues"][ue]["moyenne"]["rang"]} / {bul["ues"][ue]["moyenne"]["total"]}' + for ue in self.ues_acronyms + ], ["ECTS"] + [ f'{self.decision_ues[ue]["ects"]:g}' if ue in self.decision_ues else "" @@ -496,17 +498,17 @@ class BulletinGeneratorBUTCourt(BulletinGeneratorStandard): def boite_decisions_jury(self): """La boite en bas à droite avec jury""" - txt = f"""ECTS acquis : {self.ects_total:g}
""" + txt = f"""ECTS acquis en BUT : {self.ects_total:g}
""" if self.bul["semestre"]["decision_annee"]: txt += f""" Jury tenu le { - datetime.datetime.fromisoformat(self.bul["semestre"]["decision_annee"]["date"]).strftime("%d/%m/%Y à %H:%M") + datetime.datetime.fromisoformat(self.bul["semestre"]["decision_annee"]["date"]).strftime("%d/%m/%Y") }, année BUT {self.bul["semestre"]["decision_annee"]["code"]}.
""" if self.bul["semestre"]["autorisation_inscription"]: txt += ( - "Autorisé à s'inscrire en " + "
Autorisé à s'inscrire en " + ", ".join( [ f"S{aut['semestre_id']}" diff --git a/app/templates/but/bulletin_court_page.j2 b/app/templates/but/bulletin_court_page.j2 index f1962d02c..1068e0167 100644 --- a/app/templates/but/bulletin_court_page.j2 +++ b/app/templates/but/bulletin_court_page.j2 @@ -100,13 +100,13 @@ {% endfor %} - Bonus + dont bonus {% for ue in ues_acronyms %} {{bul.ues[ue].bonus if bul.ues[ue].bonus != "00.00" else ""}} {% endfor %} - Malus + et malus {% for ue in ues_acronyms %} {{bul.ues[ue].malus if bul.ues[ue].malus != "00.00" else ""}} {% endfor %} @@ -114,13 +114,7 @@ Rang {% for ue in ues_acronyms %} - {{bul.ues[ue].moyenne.rang}} - {% endfor %} - - - Effectif - {% for ue in ues_acronyms %} - {{bul.ues[ue].moyenne.total}} + {{bul.ues[ue].moyenne.rang}} / {{bul.ues[ue].moyenne.total}} {% endfor %} @@ -157,18 +151,18 @@
-
ECTS acquis : {{ects_total}}
+
ECTS acquis en BUT : {{"%g"|format(ects_total)}}
{% if bul.semestre.decision_annee %} Jury tenu le {{ - datetime.datetime.fromisoformat(bul.semestre.decision_annee.date).strftime("%d/%m/%Y à %H:%M") + datetime.datetime.fromisoformat(bul.semestre.decision_annee.date).strftime("%d/%m/%Y") }}, - année BUT {{bul.semestre.decision_annee.code}}. + année BUT {{bul.semestre.decision_annee.code}}. {% endif %} {% set virg = joiner(", ") %} {% for aut in bul.semestre.autorisation_inscription -%} {% if loop.first %} - Autorisé à s'inscrire en +
Autorisé à s'inscrire en {% endif %} {{- virg() }}S{{aut.semestre_id -}} {%- if loop.last -%} diff --git a/sco_version.py b/sco_version.py index 97786e2fd..4610d0b5a 100644 --- a/sco_version.py +++ b/sco_version.py @@ -1,7 +1,7 @@ # -*- mode: python -*- # -*- coding: utf-8 -*- -SCOVERSION = "9.6.18" +SCOVERSION = "9.6.19" SCONAME = "ScoDoc"