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 a2c5be22cb - Show all commits

View File

@ -949,6 +949,7 @@ def do_formsemestre_validate_ue(
"ue_id": ue_id, "ue_id": ue_id,
"semestre_id": semestre_id, "semestre_id": semestre_id,
"is_external": is_external, "is_external": is_external,
"moy_ue": moy_ue,
} }
if date: if date:
args["event_date"] = date args["event_date"] = date
@ -965,12 +966,11 @@ def do_formsemestre_validate_ue(
cursor.execute("delete from scolar_formsemestre_validation where " + cond, args) cursor.execute("delete from scolar_formsemestre_validation where " + cond, args)
# insert # insert
args["code"] = code args["code"] = code
if code == ADM: if (code == ADM) and (moy_ue is None):
if moy_ue is None: # stocke la moyenne d'UE capitalisée:
# stocke la moyenne d'UE capitalisée: ue_status = nt.get_etud_ue_status(etudid, ue_id)
ue_status = nt.get_etud_ue_status(etudid, ue_id) moy_ue = ue_status["moy"] if ue_status else ""
moy_ue = ue_status["moy"] if ue_status else ""
args["moy_ue"] = moy_ue
log("formsemestre_validate_ue: create %s" % args) log("formsemestre_validate_ue: create %s" % args)
if code is not None: if code is not None:
scolar_formsemestre_validation_create(cnx, args) scolar_formsemestre_validation_create(cnx, args)