1
0
forked from ScoDoc/ScoDoc

Tableau évaluations: ajout colonne type

This commit is contained in:
Emmanuel Viennet 2024-05-20 23:29:25 +02:00
parent 69780b3f24
commit f29002a57d
2 changed files with 10 additions and 4 deletions

View File

@ -70,8 +70,8 @@ def evaluations_recap_table(formsemestre: FormSemestre) -> list[dict]:
Colonnes:
- code (UE ou module),
- titre
- type évaluation
- complete
- publiée
- inscrits (non dem. ni def.)
- nb notes manquantes
- nb ATT
@ -81,9 +81,10 @@ def evaluations_recap_table(formsemestre: FormSemestre) -> list[dict]:
rows = []
titles = {
"type": "",
"code": "Code",
"code": "Module",
"titre": "",
"date": "Date",
"type_evaluation": "Type",
"complete": "Comptée",
"inscrits": "Inscrits",
"manquantes": "Manquantes", # notes eval non entrées
@ -114,7 +115,9 @@ def evaluations_recap_table(formsemestre: FormSemestre) -> list[dict]:
rows.append(row)
line_idx += 1
for evaluation_id in modimpl_results.evals_notes:
e = db.session.get(Evaluation, evaluation_id)
e: Evaluation = db.session.get(Evaluation, evaluation_id)
if e is None:
continue # ignore errors (rare race conditions?)
eval_etat = modimpl_results.evaluations_etat[evaluation_id]
row = {
"type": "",
@ -128,6 +131,7 @@ def evaluations_recap_table(formsemestre: FormSemestre) -> list[dict]:
"_titre_target_attrs": 'class="discretelink"',
"date": e.date_debut.strftime(scu.DATE_FMT) if e.date_debut else "",
"_date_order": e.date_debut.isoformat() if e.date_debut else "",
"type_evaluation": e.type_abbrev(),
"complete": "oui" if eval_etat.is_complete else "non",
"_complete_target": "#",
"_complete_target_attrs": (

View File

@ -4831,7 +4831,9 @@ table.evaluations_recap th.titre {
}
table.evaluations_recap td.complete,
table.evaluations_recap th.complete {
table.evaluations_recap th.complete,
table.evaluations_recap td.type_evaluation,
table.evaluations_recap th.type_evaluation {
text-align: center;
}