forked from ScoDoc/ScoDoc
formation_export: n'exporte plus les UE externes
This commit is contained in:
parent
2fe9e5ec39
commit
e8ce1e303e
@ -93,12 +93,21 @@ def formation_has_locked_sems(formation_id):
|
||||
return sems
|
||||
|
||||
|
||||
def formation_export(formation_id, export_ids=False, export_tags=True, format=None):
|
||||
def formation_export(
|
||||
formation_id,
|
||||
export_ids=False,
|
||||
export_tags=True,
|
||||
export_external_ues=False,
|
||||
format=None,
|
||||
):
|
||||
"""Get a formation, with UE, matieres, modules
|
||||
in desired format
|
||||
"""
|
||||
F = formation_list(args={"formation_id": formation_id})[0]
|
||||
ues = sco_edit_ue.ue_list({"formation_id": formation_id})
|
||||
selector = {"formation_id": formation_id}
|
||||
if not export_external_ues:
|
||||
selector["is_external"] = False
|
||||
ues = sco_edit_ue.ue_list(selector)
|
||||
F["ue"] = ues
|
||||
for ue in ues:
|
||||
ue_id = ue["ue_id"]
|
||||
|
Loading…
Reference in New Issue
Block a user