forked from ScoDoc/DocScoDoc
Fix: export excel des evaluations en attente
This commit is contained in:
parent
9b5f766500
commit
7794fff4a5
@ -337,7 +337,7 @@ def do_evaluation_list_in_sem(context, formsemestre_id):
|
||||
'visibulletin': 1} ]
|
||||
|
||||
"""
|
||||
req = "select E.* from notes_evaluation E, notes_moduleimpl MI where MI.formsemestre_id = %(formsemestre_id)s and MI.moduleimpl_id = E.moduleimpl_id"
|
||||
req = "select E.* from notes_evaluation E, notes_moduleimpl MI where MI.formsemestre_id = %(formsemestre_id)s and MI.moduleimpl_id = E.moduleimpl_id order by moduleimpl_id, numero desc, jour desc, heure_debut desc"
|
||||
cnx = context.GetDBConnexion()
|
||||
cursor = cnx.cursor(cursor_factory=ScoDocCursor)
|
||||
cursor.execute(req, {"formsemestre_id": formsemestre_id})
|
||||
|
@ -337,12 +337,11 @@ def moduleimpl_status(context, moduleimpl_id=None, partition_id=None, REQUEST=No
|
||||
% etat["last_modif"].strftime("%d/%m/%Y à %Hh%M")
|
||||
)
|
||||
H.append('<span class="evalindex_cont">')
|
||||
if has_expression:
|
||||
if has_expression or True:
|
||||
H.append(
|
||||
"""<span class="evalindex" title="Indice dans les vecteurs (formules)">%02d</span>"""
|
||||
"""<span class="evalindex" title="Indice dans les vecteurs (formules)">%2d</span>"""
|
||||
% eval_index
|
||||
)
|
||||
|
||||
# Fleches:
|
||||
H.append('<span class="eval_arrows_chld">')
|
||||
if eval_index != (len(ModEvals) - 1) and caneditevals:
|
||||
|
@ -764,7 +764,11 @@ def _list_notes_evals(context, evals, etudid):
|
||||
"""
|
||||
L = []
|
||||
for e in evals:
|
||||
if e["etat"]["evalcomplete"] or e["publish_incomplete"]:
|
||||
if (
|
||||
e["etat"]["evalcomplete"]
|
||||
or e["etat"]["evalattente"]
|
||||
or e["publish_incomplete"]
|
||||
):
|
||||
NotesDB = context._notes_getall(e["evaluation_id"])
|
||||
if NotesDB.has_key(etudid):
|
||||
val = NotesDB[etudid]["value"]
|
||||
@ -779,9 +783,15 @@ def _list_notes_evals(context, evals, etudid):
|
||||
def _list_notes_evals_titles(context, codemodule, evals):
|
||||
"""Liste des titres des evals completes"""
|
||||
L = []
|
||||
eval_index = len(evals) - 1
|
||||
for e in evals:
|
||||
if e["etat"]["evalcomplete"] or e["publish_incomplete"]:
|
||||
L.append(codemodule + "-" + str(e["numero"]) + "-" + e["jour"].isoformat())
|
||||
if (
|
||||
e["etat"]["evalcomplete"]
|
||||
or e["etat"]["evalattente"]
|
||||
or e["publish_incomplete"]
|
||||
):
|
||||
L.append(codemodule + "-" + str(eval_index) + "-" + e["jour"].isoformat())
|
||||
eval_index -= 1
|
||||
return L
|
||||
|
||||
|
||||
@ -789,7 +799,11 @@ def _list_notes_evals_stats(context, evals, key):
|
||||
"""Liste des stats (moy, ou rien!) des evals completes"""
|
||||
L = []
|
||||
for e in evals:
|
||||
if e["etat"]["evalcomplete"] or e["publish_incomplete"]:
|
||||
if (
|
||||
e["etat"]["evalcomplete"]
|
||||
or e["etat"]["evalattente"]
|
||||
or e["publish_incomplete"]
|
||||
):
|
||||
if key == "moy":
|
||||
val = e["etat"]["moy_num"]
|
||||
L.append(fmt_note(val, keep_numeric=True))
|
||||
|
@ -1338,6 +1338,7 @@ span.evalindex_cont {
|
||||
}
|
||||
span.evalindex {
|
||||
font-weight: normal;
|
||||
font-size: 80%;
|
||||
margin-right: 5px;
|
||||
}
|
||||
.eval_arrows_chld {
|
||||
|
Loading…
Reference in New Issue
Block a user