mirror of
https://gitlab.com/Chill-Projet/chill-bundles.git
synced 2026-02-20 23:29:59 +00:00
Register SubjectConverterInterface for autoconfiguration and add new audit services
- Registered `SubjectConverterInterface` for autoconfiguration with the `chill_main.audit_subject_converter` tag. - Added `audit.yaml` to configure audit-related services and enable service discovery for the `Audit` namespace. - Updated `services.yaml` to include the new `audit.yaml` configuration.
This commit is contained in:
@@ -11,6 +11,7 @@ declare(strict_types=1);
|
||||
|
||||
namespace Chill\MainBundle;
|
||||
|
||||
use Chill\MainBundle\Audit\SubjectConverterInterface;
|
||||
use Chill\MainBundle\Cron\CronJobInterface;
|
||||
use Chill\MainBundle\CRUD\CompilerPass\CRUDControllerCompilerPass;
|
||||
use Chill\MainBundle\DependencyInjection\CompilerPass\ACLFlagsCompilerPass;
|
||||
@@ -64,6 +65,8 @@ class ChillMainBundle extends Bundle
|
||||
->addTag('chill_main.provide_role');
|
||||
$container->registerForAutoconfiguration(NotificationFlagProviderInterface::class)
|
||||
->addTag('chill_main.notification_flag_provider');
|
||||
$container->registerForAutoconfiguration(SubjectConverterInterface::class)
|
||||
->addTag('chill_main.audit_subject_converter');
|
||||
|
||||
$container->addCompilerPass(new SearchableServicesCompilerPass(), \Symfony\Component\DependencyInjection\Compiler\PassConfig::TYPE_BEFORE_OPTIMIZATION, 0);
|
||||
$container->addCompilerPass(new ConfigConsistencyCompilerPass(), \Symfony\Component\DependencyInjection\Compiler\PassConfig::TYPE_BEFORE_OPTIMIZATION, 0);
|
||||
|
||||
@@ -3,6 +3,7 @@ parameters:
|
||||
|
||||
imports:
|
||||
- ./services/clock.yaml
|
||||
- ./services/audit.yaml
|
||||
|
||||
services:
|
||||
_defaults:
|
||||
|
||||
16
src/Bundle/ChillMainBundle/config/services/audit.yaml
Normal file
16
src/Bundle/ChillMainBundle/config/services/audit.yaml
Normal file
@@ -0,0 +1,16 @@
|
||||
services:
|
||||
_defaults:
|
||||
autowire: true
|
||||
autoconfigure: true
|
||||
|
||||
Chill\MainBundle\Audit\:
|
||||
resource: '../../Audit/*'
|
||||
exclude:
|
||||
- '../../Audit/Subject.php'
|
||||
- '../../Audit/AuditEvent.php'
|
||||
- '../../Audit/Exception/'
|
||||
- '../../Audit/Exception/*'
|
||||
|
||||
Chill\MainBundle\Audit\SubjectConverterManager:
|
||||
arguments:
|
||||
$converters: !tagged_iterator chill_main.audit_subject_converter
|
||||
Reference in New Issue
Block a user