geonature.core.gn_meta.models.aframework

Module Contents

Classes

TAcquisitionFramework

The base class of the SQLAlchemy.Model declarative model class.

class geonature.core.gn_meta.models.aframework.TAcquisitionFramework[source]

Bases: geonature.core.gn_meta.models.commons.db.Model

The base class of the SQLAlchemy.Model declarative model class.

To define models, subclass db.Model, not this. To customize db.Model, subclass this and pass it as model_class to SQLAlchemy. To customize db.Model at the metaclass level, pass an already created declarative model class as model_class.

__tablename__ = 't_acquisition_frameworks'[source]
__table_args__[source]
id_acquisition_framework[source]
unique_acquisition_framework_id[source]
acquisition_framework_name[source]
acquisition_framework_desc[source]
id_nomenclature_territorial_level[source]
territory_desc[source]
keywords[source]
id_nomenclature_financing_type[source]
target_description[source]
ecologic_or_geologic_target[source]
acquisition_framework_parent_id[source]
is_parent[source]
opened[source]
id_digitizer[source]
acquisition_framework_start_date[source]
acquisition_framework_end_date[source]
meta_create_date[source]
meta_update_date[source]
initial_closing_date[source]
creator[source]
nomenclature_territorial_level[source]
nomenclature_financing_type[source]
cor_af_actor[source]
cor_objectifs[source]
cor_volets_sinp[source]
cor_territories[source]
bibliographical_references[source]
t_datasets[source]
datasets[source]
user_actors()[source]
organism_actors()[source]
is_deletable()[source]
has_instance_permission(scope, _through_ds=True)[source]
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

classmethod _get_read_scope(user=None)[source]
classmethod filter_by_scope(scope, *, query, user=None)[source]
classmethod filter_by_readable(*, query, user=None)[source]

Return the afs where the user has autorization via its CRUVED

classmethod filter_by_areas(areas, *, query)[source]

Filter meta by areas

classmethod filter_by_params(params={}, *, _ds_search=True, query=None)[source]