diff --git a/atlas/atlasRoutes.py b/atlas/atlasRoutes.py index e5f5624e..6b586e3e 100644 --- a/atlas/atlasRoutes.py +++ b/atlas/atlasRoutes.py @@ -320,10 +320,7 @@ def is_statut_in_groupe(statut, groupe): groupes_statuts = [] for config_groupe in config.GROUPES_STATUTS: - groupe = { - "label": config_groupe.get("label", ""), - "statuts": [] - } + groupe = {"label": config_groupe.get("label", ""), "statuts": []} groupes_statuts.append(groupe) for statut in statuts: if is_statut_in_groupe(statut, config_groupe): diff --git a/atlas/configuration/config_schema.py b/atlas/configuration/config_schema.py index 8d3e6da0..7f849826 100644 --- a/atlas/configuration/config_schema.py +++ b/atlas/configuration/config_schema.py @@ -143,25 +143,13 @@ class Meta: GROUPES_STATUTS = fields.List( fields.Dict, load_default=[ - { - "label": "Monde", - "origins": [ - {"cd_type_statut": "LRM", "cd_sig": "WORLD"} - ] - }, - { - "label": "Europe", - "origins": [ - {"cd_type_statut": "LRE", "cd_sig": "EUROPE"} - ] - }, + {"label": "Monde", "origins": [{"cd_type_statut": "LRM", "cd_sig": "WORLD"}]}, + {"label": "Europe", "origins": [{"cd_type_statut": "LRE", "cd_sig": "EUROPE"}]}, { "label": "France métropolitaine", - "origins": [ - {"cd_type_statut": "LRN", "cd_sig": "TERFXFR"} - ] - } - ] + "origins": [{"cd_type_statut": "LRN", "cd_sig": "TERFXFR"}], + }, + ], ) RANG_STAT = fields.List( diff --git a/atlas/modeles/repositories/vmStatutBdcRepository.py b/atlas/modeles/repositories/vmStatutBdcRepository.py index a802e657..9b21bb9d 100644 --- a/atlas/modeles/repositories/vmStatutBdcRepository.py +++ b/atlas/modeles/repositories/vmStatutBdcRepository.py @@ -7,13 +7,13 @@ def get_taxons_statut_bdc(connection, cd_ref): statuts = list() for row in result: statut = { - 'rq_statut': row.rq_statut, - 'code_statut': row.code_statut, - 'label_statut': row.label_statut, - 'cd_type_statut': row.cd_type_statut, - 'lb_type_statut': row.lb_type_statut, - 'lb_adm_tr': row.lb_adm_tr, - 'cd_sig': row.cd_sig, + "rq_statut": row.rq_statut, + "code_statut": row.code_statut, + "label_statut": row.label_statut, + "cd_type_statut": row.cd_type_statut, + "lb_type_statut": row.lb_type_statut, + "lb_adm_tr": row.lb_adm_tr, + "cd_sig": row.cd_sig, } statuts.append(statut) return statuts