forked from ScoDoc/ScoDoc
fix bul json si ects None
This commit is contained in:
parent
d79da28aba
commit
f672c17bbf
@ -189,10 +189,10 @@ def formsemestre_bulletinetud_published_dict(
|
|||||||
d["ue_capitalisee"] = []
|
d["ue_capitalisee"] = []
|
||||||
for ue in ues:
|
for ue in ues:
|
||||||
ue_status = nt.get_etud_ue_status(etudid, ue["ue_id"])
|
ue_status = nt.get_etud_ue_status(etudid, ue["ue_id"])
|
||||||
try:
|
if ue["ects"] is None:
|
||||||
ects_txt = str(int(ue["ects"]))
|
|
||||||
except ValueError:
|
|
||||||
ects_txt = ""
|
ects_txt = ""
|
||||||
|
else:
|
||||||
|
ects_txt = f"{ue['ects']:2.3g}"
|
||||||
u = dict(
|
u = dict(
|
||||||
id=ue["ue_id"],
|
id=ue["ue_id"],
|
||||||
numero=scu.quote_xml_attr(ue["numero"]),
|
numero=scu.quote_xml_attr(ue["numero"]),
|
||||||
|
Loading…
Reference in New Issue
Block a user