translator_directory.collections.documents
Attributes
Classes
Manages files. |
Module Contents
- translator_directory.collections.documents.DEFAULT_DOCUMENT_CATEGORIES = ('Antrag', 'Diplome und Zertifikate', 'Abklärungen', 'Bestätigungen der Koordinationsstelle',...[source]
- class translator_directory.collections.documents.TranslatorDocumentCollection(session: sqlalchemy.orm.Session, translator_id: uuid.UUID, category: str | None)[source]
Bases:
onegov.file.FileCollection
[onegov.file.File
]Manages files.
- Parameters:
session – The SQLAlchemy db session to use.
type – The polymorphic type to use and to filter for, or ‘*’ for all.
allow_duplicates –
Prevents duplicates if set to false. Duplicates are detected before pre-processing, so already stored files may be downloaded and added again, as they might have changed during the upload.
Note that this does not change existing files. It only prevents new duplicates from being added.