From b4316ea228fe189b808f1d9d47307b0ffb49afbb Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ren=C3=A9=20Hrdina?= Date: Wed, 24 Nov 2021 12:43:46 +0000 Subject: [PATCH 01/11] wip: make bundle compatible with ibexa v3 --- bundle/Controller/Admin/Export/Export.php | 2 +- .../NetgenInformationCollectionExtension.php | 2 + bundle/Resources/views/admin/view.html.twig | 2 +- .../Resources/views/email/default.html.twig | 4 +- lib/API/Value/InformationCollectionStruct.php | 6 +- lib/Core/Action/BaseEmailAction.php | 20 ++-- .../AutoResponderProvider.php | 21 ++-- .../EmailDataProvider/DefaultProvider.php | 105 +++++------------- lib/Core/Factory/EmailDataFactory.php | 10 +- lib/Core/Mailer/SwiftMailerBasedMailer.php | 51 +++++++-- lib/Core/Mailer/SymfonyMailerBasedMailer.php | 10 +- lib/Resources/config/actions.yml | 7 +- lib/Resources/config/email_data_providers.yml | 8 ++ lib/Resources/config/factories.yml | 9 +- lib/Resources/config/mailers.yml | 9 ++ lib/Resources/config/services.yml | 4 +- 16 files changed, 133 insertions(+), 137 deletions(-) create mode 100644 lib/Resources/config/email_data_providers.yml create mode 100644 lib/Resources/config/mailers.yml diff --git a/bundle/Controller/Admin/Export/Export.php b/bundle/Controller/Admin/Export/Export.php index fc442760..79d98382 100644 --- a/bundle/Controller/Admin/Export/Export.php +++ b/bundle/Controller/Admin/Export/Export.php @@ -3,12 +3,12 @@ namespace Netgen\Bundle\InformationCollectionBundle\Controller\Admin\Export; use eZ\Publish\Core\MVC\Symfony\Security\Authorization\Attribute; +use Netgen\Bundle\InformationCollectionBundle\Form\ExportType; use Symfony\Bundle\FrameworkBundle\Controller\AbstractController; use Netgen\InformationCollection\API\Value\Export\ExportCriteria; use Netgen\InformationCollection\API\Service\Exporter; use Netgen\InformationCollection\Core\Export\ExportResponseFormatterRegistry; use Symfony\Component\HttpFoundation\Request; -use Netgen\InformationCollection\Form\Type\ExportType; use eZ\Publish\API\Repository\ContentService; final class Export extends AbstractController diff --git a/bundle/DependencyInjection/NetgenInformationCollectionExtension.php b/bundle/DependencyInjection/NetgenInformationCollectionExtension.php index f36e19d5..ef4c0d24 100644 --- a/bundle/DependencyInjection/NetgenInformationCollectionExtension.php +++ b/bundle/DependencyInjection/NetgenInformationCollectionExtension.php @@ -42,6 +42,8 @@ public function load(array $configs, ContainerBuilder $container) $libResourceLoader->load('services.yml'); $libResourceLoader->load('parameters.yml'); $libResourceLoader->load('default_settings.yml'); + $libResourceLoader->load('email_data_providers.yml'); + $libResourceLoader->load('mailers.yml'); $this->processSemanticConfig($container, $config); diff --git a/bundle/Resources/views/admin/view.html.twig b/bundle/Resources/views/admin/view.html.twig index fad83a99..a1d0eddb 100644 --- a/bundle/Resources/views/admin/view.html.twig +++ b/bundle/Resources/views/admin/view.html.twig @@ -32,7 +32,7 @@