From 12b9ac4da1ea938e09e644b27051b58ae1f87690 Mon Sep 17 00:00:00 2001 From: Julien Rosset Date: Fri, 26 Apr 2024 18:21:46 +0200 Subject: [PATCH] Configuration: enable Gedmo extensions --- config/packages/doctrine.yaml | 24 +++++++++++++++++++ config/packages/stof_doctrine_extensions.yaml | 13 +++++++++- 2 files changed, 36 insertions(+), 1 deletion(-) diff --git a/config/packages/doctrine.yaml b/config/packages/doctrine.yaml index bdff96f..4c61c2a 100644 --- a/config/packages/doctrine.yaml +++ b/config/packages/doctrine.yaml @@ -16,6 +16,30 @@ doctrine: dir: '%kernel.project_dir%/src/Entity' prefix: 'App\Entity' alias: App + gedmo_translatable: + type: annotation + prefix: Gedmo\Translatable\Entity + dir: "%kernel.project_dir%/vendor/gedmo/doctrine-extensions/src/Translatable/Entity" + alias: GedmoTranslatable # (optional) it will default to the name set for the mapping + is_bundle: false + gedmo_translator: + type: annotation + prefix: Gedmo\Translator\Entity + dir: "%kernel.project_dir%/vendor/gedmo/doctrine-extensions/src/Translator/Entity" + alias: GedmoTranslator # (optional) it will default to the name set for the mapping + is_bundle: false + gedmo_loggable: + type: annotation + prefix: Gedmo\Loggable\Entity + dir: "%kernel.project_dir%/vendor/gedmo/doctrine-extensions/src/Loggable/Entity" + alias: GedmoLoggable # (optional) it will default to the name set for the mapping + is_bundle: false + gedmo_tree: + type: annotation + prefix: Gedmo\Tree\Entity + dir: "%kernel.project_dir%/vendor/gedmo/doctrine-extensions/src/Tree/Entity" + alias: GedmoTree # (optional) it will default to the name set for the mapping + is_bundle: false when@test: doctrine: diff --git a/config/packages/stof_doctrine_extensions.yaml b/config/packages/stof_doctrine_extensions.yaml index 6979b41..35b61b9 100644 --- a/config/packages/stof_doctrine_extensions.yaml +++ b/config/packages/stof_doctrine_extensions.yaml @@ -2,6 +2,17 @@ # See the official DoctrineExtensions documentation for more details: https://github.com/doctrine-extensions/DoctrineExtensions/tree/main/doc stof_doctrine_extensions: default_locale: en_US + uploadable: + # Default file path: This is one of the three ways you can configure the path for the Uploadable extension + default_file_path: "%kernel.project_dir%/public/uploads" + + # Mime type guesser class: Optional. By default, we provide an adapter for the one present in the Mime component of Symfony + mime_type_guesser_class: Stof\DoctrineExtensionsBundle\Uploadable\MimeTypeGuesserAdapter + + # Default file info class implementing FileInfoInterface: Optional. By default we provide a class which is prepared to receive an UploadedFile instance. + default_file_info_class: Stof\DoctrineExtensionsBundle\Uploadable\UploadedFileInfo orm: default: - timestampable: true \ No newline at end of file + timestampable: true + tree: true + uploadable: true \ No newline at end of file