Mise à jour de 'app/scodoc/sco_undo_notes.py'

Remplacement uid par user_name
Ajout colonne prenom (étudiant) pour lever ambiguité lorsqu'il y a des homonymes
This commit is contained in:
pascal.bouron 2021-12-12 21:11:18 +01:00
parent 3eda56e89c
commit 861a7da8a1

View File

@ -179,13 +179,14 @@ def formsemestre_list_saisies_notes(formsemestre_id, format="html"):
""" """
sem = sco_formsemestre.get_formsemestre(formsemestre_id, raise_soft_exc=True) sem = sco_formsemestre.get_formsemestre(formsemestre_id, raise_soft_exc=True)
r = ndb.SimpleDictFetch( r = ndb.SimpleDictFetch(
"""SELECT i.nom, code_nip, n.*, mod.titre, e.description, e.jour """SELECT i.nom, i.prenom, code_nip, n.*, mod.titre, e.description, e.jour, u.user_name
FROM notes_notes n, notes_evaluation e, notes_moduleimpl mi, FROM notes_notes n, notes_evaluation e, notes_moduleimpl mi,
notes_modules mod, identite i notes_modules mod, identite i, \"user\" u
WHERE mi.id = e.moduleimpl_id WHERE mi.id = e.moduleimpl_id
and mi.module_id = mod.id and mi.module_id = mod.id
and e.id = n.evaluation_id and e.id = n.evaluation_id
and i.id = n.etudid and i.id = n.etudid
and u.id = n.uid
and mi.formsemestre_id = %(formsemestre_id)s and mi.formsemestre_id = %(formsemestre_id)s
ORDER BY date desc ORDER BY date desc
""", """,
@ -195,8 +196,9 @@ def formsemestre_list_saisies_notes(formsemestre_id, format="html"):
"date", "date",
"code_nip", "code_nip",
"nom", "nom",
"prenom",
"value", "value",
"uid", "user_name",
"titre", "titre",
"description", "description",
"jour", "jour",
@ -204,11 +206,12 @@ def formsemestre_list_saisies_notes(formsemestre_id, format="html"):
) )
titles = { titles = {
"code_nip": "NIP", "code_nip": "NIP",
"nom": "Etudiant", "nom": "nom",
"prenom": "prenom",
"date": "Date", "date": "Date",
"value": "Note", "value": "Note",
"comment": "Remarque", "comment": "Remarque",
"uid": "Enseignant", "user_name": "Enseignant",
"titre": "Module", "titre": "Module",
"description": "Evaluation", "description": "Evaluation",
"jour": "Date éval.", "jour": "Date éval.",