geonature.core.imports.checks.sql.user¶
Classes¶
Functions¶
|
Find matching user for a given transient table and csv column. |
|
Module Contents¶
- geonature.core.imports.checks.sql.user.user_matching(imprt: geonature.core.imports.models.TImports, field: geonature.core.imports.models.BibFields)[source]¶
Find matching user for a given transient table and csv column.
Parameters¶
- imprtTImports
The import object which contains the transient table.
- fieldBibFields
field use to fetch user name strings
Returns¶
- dict
A dictionary of users name (as it appears in the source file) as key and a dictionary of matching information as value. The matching information contains id_role, identifiant, nom_complet.
Notes¶
The matching is done by computing the similarity between the source file usernames and the nom_complet of the users in the utilisateurs.t_roles table.
- geonature.core.imports.checks.sql.user.map_observer_matching(imprt: geonature.core.imports.models.TImports, entity: geonature.core.imports.models.Entity, observer_field: geonature.core.imports.models.BibFields)[source]¶