mirror of
https://github.com/ae-utbm/sith.git
synced 2024-11-22 06:03:20 +00:00
api: fix uv manager acquisition if uv is only available in spring
This commit is contained in:
parent
86bc491df4
commit
f533c39e67
@ -105,7 +105,10 @@ def make_clean_uv(short_uv, full_uv):
|
||||
res["hours_{}".format(activity["code"])] += activity["nbh"] // 60
|
||||
|
||||
# wrong if the manager changes depending on the semester
|
||||
res["manager"] = full_uv["automne"]["responsable"]
|
||||
semester = full_uv.get("automne", None)
|
||||
if not semester:
|
||||
semester = full_uv.get("printemps", {})
|
||||
res["manager"] = semester.get("responsable", "")
|
||||
|
||||
res["title"] = full_uv["libelle"]
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user