From 988f577f6eb6e944247ecd0fcdea8f24ee51bab5 Mon Sep 17 00:00:00 2001 From: Emmanuel Viennet Date: Mon, 20 Nov 2023 11:23:40 +0100 Subject: [PATCH] Fix formation_import_xml (typo) --- app/scodoc/sco_formations.py | 6 +++--- sco_version.py | 2 +- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/app/scodoc/sco_formations.py b/app/scodoc/sco_formations.py index d181098714..e17b4945a2 100644 --- a/app/scodoc/sco_formations.py +++ b/app/scodoc/sco_formations.py @@ -322,13 +322,13 @@ def formation_import_xml(doc: str, import_tags=True, use_local_refcomp=False): referentiel_competence_id = _formation_retreive_refcomp(f_dict) f_dict["referentiel_competence_id"] = referentiel_competence_id # find new version number - acronyme_lower = f_dict["acronyme"].lower if f_dict["acronyme"] else "" - titre_lower = f_dict["titre"].lower if f_dict["titre"] else "" + acronyme_lower = f_dict["acronyme"].lower() if f_dict["acronyme"] else "" + titre_lower = f_dict["titre"].lower() if f_dict["titre"] else "" formations: list[Formation] = Formation.query.filter_by( dept_id=f_dict["dept_id"] ).filter( db.func.lower(Formation.acronyme) == acronyme_lower, - db.func(Formation.titre) == titre_lower, + db.func.lower(Formation.titre) == titre_lower, ) if formations.count(): version = max(f.version or 0 for f in formations) diff --git a/sco_version.py b/sco_version.py index 26bbad3c4d..e8a195ffcc 100644 --- a/sco_version.py +++ b/sco_version.py @@ -1,7 +1,7 @@ # -*- mode: python -*- # -*- coding: utf-8 -*- -SCOVERSION = "9.6.57" +SCOVERSION = "9.6.58" SCONAME = "ScoDoc"