You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

31 lines
744B

  1. <?php
  2. namespace App\Controller;
  3. use App\Container\CollectifData\CollectifDataContainer;
  4. use App\Container\Site\BlockContainer;
  5. trait ControllerTrait
  6. {
  7. public static function getSubscribedServices(): array
  8. {
  9. return array_merge(
  10. parent::getSubscribedServices(),
  11. [
  12. CollectifDataContainer::class => CollectifDataContainer::class,
  13. BlockContainer::class => BlockContainer::class,
  14. ]
  15. );
  16. }
  17. public function getCollectifDataContainer(): CollectifDataContainer
  18. {
  19. return $this->get(CollectifDataContainer::class);
  20. }
  21. public function getBlockContainer(): BlockContainer
  22. {
  23. return $this->get(BlockContainer::class);
  24. }
  25. }