geonature.core.gn_meta.models¶
Submodules¶
Attributes¶
Classes¶
Functions¶
|
This function gets the scopes permissions for each one of the 6 actions in "CRUVED", |
|
This function gets the scopes permissions for each one of the 6 actions in "CRUVED", |
Package Contents¶
- geonature.core.gn_meta.models.get_scopes_by_action(id_role=None, module_code=None, object_code=None)[source]¶
This function gets the scopes permissions for each one of the 6 actions in « CRUVED », that match (id_role, module_code, object_code)
:returns : (dict) A dict of the scope for each one of the 6 actions (the char in « CRUVED »)
- class geonature.core.gn_meta.models.TDatasets[source]¶
Bases:
geonature.core.gn_meta.models.commons.db.Model
- __tablename__ = 't_datasets'¶
- __table_args__¶
- id_dataset¶
- unique_dataset_id¶
- id_acquisition_framework¶
- acquisition_framework¶
- dataset_name¶
- dataset_shortname¶
- dataset_desc¶
- id_nomenclature_data_type¶
- keywords¶
- marine_domain¶
- terrestrial_domain¶
- id_nomenclature_dataset_objectif¶
- bbox_west¶
- bbox_east¶
- bbox_south¶
- bbox_north¶
- id_nomenclature_collecting_method¶
- id_nomenclature_data_origin¶
- id_nomenclature_source_status¶
- id_nomenclature_resource_type¶
- meta_create_date¶
- meta_update_date¶
- active¶
- validable¶
- id_digitizer¶
- digitizer¶
- creator¶
- id_taxa_list¶
- modules¶
- nomenclature_data_type¶
- nomenclature_dataset_objectif¶
- nomenclature_collecting_method¶
- nomenclature_data_origin¶
- nomenclature_source_status¶
- nomenclature_resource_type¶
- cor_territories¶
- cor_dataset_actor¶
- additional_fields¶
- filter_by_readable(query, user=None)[source]¶
Return the datasets where the user has autorization via its CRUVED
- class geonature.core.gn_meta.models.TAcquisitionFramework[source]¶
Bases:
geonature.core.gn_meta.models.commons.db.Model
- __tablename__ = 't_acquisition_frameworks'¶
- __table_args__¶
- id_acquisition_framework¶
- unique_acquisition_framework_id¶
- acquisition_framework_name¶
- acquisition_framework_desc¶
- id_nomenclature_territorial_level¶
- territory_desc¶
- keywords¶
- id_nomenclature_financing_type¶
- target_description¶
- ecologic_or_geologic_target¶
- acquisition_framework_parent_id¶
- is_parent¶
- opened¶
- id_digitizer¶
- acquisition_framework_start_date¶
- acquisition_framework_end_date¶
- meta_create_date¶
- meta_update_date¶
- initial_closing_date¶
- creator¶
- nomenclature_territorial_level¶
- nomenclature_financing_type¶
- cor_af_actor¶
- cor_objectifs¶
- cor_volets_sinp¶
- cor_territories¶
- bibliographical_references¶
- t_datasets¶
- datasets¶
- static get_id(uuid_af)[source]¶
return the acquisition framework’s id from its UUID if exist or None
- static get_user_af(user, only_query=False, only_user=False)[source]¶
get the af(s) where the user is actor (himself or with its organism - only himelsemf id only_use=True) or digitizer param:
user from TRole model
only_query: boolean (return the query not the id_datasets allowed if true)
only_user: boolean: return only the dataset where user himself is actor (not with its organoism)
return: a list of id_dataset or a query
- class geonature.core.gn_meta.models.DateFilterSchema[source]¶
Bases:
marshmallow.Schema
- year¶
- month¶
- day¶
- class geonature.core.gn_meta.models.MetadataFilterSchema[source]¶
Bases:
marshmallow.Schema
- uuid¶
- name¶
- date¶
- person¶
- organism¶
- areas¶
- search¶
- class geonature.core.gn_meta.models.CorAcquisitionFrameworkActor[source]¶
Bases:
geonature.utils.env.DB.Model
- __tablename__ = 'cor_acquisition_framework_actor'¶
- __table_args__¶
- id_cafa¶
- id_acquisition_framework¶
- id_role¶
- id_organism¶
- id_nomenclature_actor_role¶
- nomenclature_actor_role¶
- role¶
- organism¶
- class geonature.core.gn_meta.models.CorDatasetActor[source]¶
Bases:
geonature.utils.env.DB.Model
- __tablename__ = 'cor_dataset_actor'¶
- __table_args__¶
- id_cda¶
- id_dataset¶
- id_role¶
- id_organism¶
- id_nomenclature_actor_role¶
- nomenclature_actor_role¶
- role¶
- organism¶
- class geonature.core.gn_meta.models.CorDatasetProtocol[source]¶
Bases:
geonature.utils.env.DB.Model
- __tablename__ = 'cor_dataset_protocol'¶
- __table_args__¶
- id_cdp¶
- id_dataset¶
- id_protocol¶
- class geonature.core.gn_meta.models.TBibliographicReference[source]¶
Bases:
geonature.utils.env.db.Model
- __tablename__ = 't_bibliographical_references'¶
- __table_args__¶
- id_bibliographic_reference¶
- id_acquisition_framework¶
- publication_url¶
- publication_reference¶
- geonature.core.gn_meta.models.get_scopes_by_action(id_role=None, module_code=None, object_code=None)[source]¶
This function gets the scopes permissions for each one of the 6 actions in « CRUVED », that match (id_role, module_code, object_code)
:returns : (dict) A dict of the scope for each one of the 6 actions (the char in « CRUVED »)
- class geonature.core.gn_meta.models.TDatasets[source]¶
Bases:
geonature.core.gn_meta.models.commons.db.Model
- __tablename__ = 't_datasets'¶
- __table_args__¶
- id_dataset¶
- unique_dataset_id¶
- id_acquisition_framework¶
- acquisition_framework¶
- dataset_name¶
- dataset_shortname¶
- dataset_desc¶
- id_nomenclature_data_type¶
- keywords¶
- marine_domain¶
- terrestrial_domain¶
- id_nomenclature_dataset_objectif¶
- bbox_west¶
- bbox_east¶
- bbox_south¶
- bbox_north¶
- id_nomenclature_collecting_method¶
- id_nomenclature_data_origin¶
- id_nomenclature_source_status¶
- id_nomenclature_resource_type¶
- meta_create_date¶
- meta_update_date¶
- active¶
- validable¶
- id_digitizer¶
- digitizer¶
- creator¶
- id_taxa_list¶
- modules¶
- nomenclature_data_type¶
- nomenclature_dataset_objectif¶
- nomenclature_collecting_method¶
- nomenclature_data_origin¶
- nomenclature_source_status¶
- nomenclature_resource_type¶
- cor_territories¶
- cor_dataset_actor¶
- additional_fields¶
- filter_by_readable(query, user=None)[source]¶
Return the datasets where the user has autorization via its CRUVED
- class geonature.core.gn_meta.models.DateFilterSchema[source]¶
Bases:
marshmallow.Schema
- year¶
- month¶
- day¶
- class geonature.core.gn_meta.models.MetadataFilterSchema[source]¶
Bases:
marshmallow.Schema
- uuid¶
- name¶
- date¶
- person¶
- organism¶
- areas¶
- search¶
- class geonature.core.gn_meta.models.CorAcquisitionFrameworkActor[source]¶
Bases:
geonature.utils.env.DB.Model
- __tablename__ = 'cor_acquisition_framework_actor'¶
- __table_args__¶
- id_cafa¶
- id_acquisition_framework¶
- id_role¶
- id_organism¶
- id_nomenclature_actor_role¶
- nomenclature_actor_role¶
- role¶
- organism¶
- class geonature.core.gn_meta.models.CorDatasetActor[source]¶
Bases:
geonature.utils.env.DB.Model
- __tablename__ = 'cor_dataset_actor'¶
- __table_args__¶
- id_cda¶
- id_dataset¶
- id_role¶
- id_organism¶
- id_nomenclature_actor_role¶
- nomenclature_actor_role¶
- role¶
- organism¶
- class geonature.core.gn_meta.models.CorDatasetProtocol[source]¶
Bases:
geonature.utils.env.DB.Model
- __tablename__ = 'cor_dataset_protocol'¶
- __table_args__¶
- id_cdp¶
- id_dataset¶
- id_protocol¶
- class geonature.core.gn_meta.models.TBibliographicReference[source]¶
Bases:
geonature.utils.env.db.Model
- __tablename__ = 't_bibliographical_references'¶
- __table_args__¶
- id_bibliographic_reference¶
- id_acquisition_framework¶
- publication_url¶
- publication_reference¶
- class geonature.core.gn_meta.models.DateFilterSchema[source]¶
Bases:
marshmallow.Schema
- year¶
- month¶
- day¶
- class geonature.core.gn_meta.models.MetadataFilterSchema[source]¶
Bases:
marshmallow.Schema
- uuid¶
- name¶
- date¶
- person¶
- organism¶
- areas¶
- search¶
- class geonature.core.gn_meta.models.CorAcquisitionFrameworkActor[source]¶
Bases:
geonature.utils.env.DB.Model
- __tablename__ = 'cor_acquisition_framework_actor'¶
- __table_args__¶
- id_cafa¶
- id_acquisition_framework¶
- id_role¶
- id_organism¶
- id_nomenclature_actor_role¶
- nomenclature_actor_role¶
- role¶
- organism¶
- class geonature.core.gn_meta.models.CorDatasetActor[source]¶
Bases:
geonature.utils.env.DB.Model
- __tablename__ = 'cor_dataset_actor'¶
- __table_args__¶
- id_cda¶
- id_dataset¶
- id_role¶
- id_organism¶
- id_nomenclature_actor_role¶
- nomenclature_actor_role¶
- role¶
- organism¶