X-Git-Url: https://git.rapsys.eu/treebundle/blobdiff_plain/2cec3e449469a1981d46d7700ed5c9c50c242595..refs/heads/master:/Repository.php?ds=inline diff --git a/Repository.php b/Repository.php index b60959f..2198636 100644 --- a/Repository.php +++ b/Repository.php @@ -17,6 +17,7 @@ use Doctrine\ORM\Mapping\ClassMetadata; use Psr\Container\ContainerInterface; +use Rapsys\PackBundle\Util\FileUtil; use Rapsys\PackBundle\Util\SluggerUtil; use Symfony\Component\Routing\RouterInterface; @@ -48,13 +49,14 @@ class Repository extends EntityRepository { * @param EntityManagerInterface $manager The EntityManagerInterface instance * @param ClassMetadata $class The ClassMetadata instance * @param ContainerInterface $container The container instance + * @param FileUtil $file The FileUtil instance * @param RouterInterface $router The router instance * @param SluggerUtil $slugger The SluggerUtil instance * @param TranslatorInterface $translator The TranslatorInterface instance * @param string $locale The current locale * @param array $languages The languages list */ - public function __construct(protected EntityManagerInterface $manager, protected ClassMetadata $class, protected ContainerInterface $container, protected RouterInterface $router, protected SluggerUtil $slugger, protected TranslatorInterface $translator, protected string $locale, protected array $languages) { + public function __construct(protected EntityManagerInterface $manager, protected ClassMetadata $class, protected ContainerInterface $container, protected FileUtil $file, protected RouterInterface $router, protected SluggerUtil $slugger, protected TranslatorInterface $translator, protected string $locale, protected array $languages) { //Call parent constructor parent::__construct($this->manager, $this->class); @@ -69,8 +71,8 @@ class Repository extends EntityRepository { $tables = [ 'Rapsys\TreeBundle\Entity\UserGroup' => $qs->getJoinTableName($manager->getClassMetadata('Rapsys\TreeBundle\Entity\User')->getAssociationMapping('groups'), $manager->getClassMetadata('Rapsys\TreeBundle\Entity\User'), $dp), 'Rapsys\TreeBundle\Entity\Album' => $qs->getTableName($manager->getClassMetadata('Rapsys\TreeBundle\Entity\Album'), $dp), - 'Rapsys\TreeBundle\Entity\Asset' => $qs->getTableName($manager->getClassMetadata('Rapsys\TreeBundle\Entity\Asset'), $dp), 'Rapsys\TreeBundle\Entity\Civility' => $qs->getTableName($manager->getClassMetadata('Rapsys\TreeBundle\Entity\Civility'), $dp), + 'Rapsys\TreeBundle\Entity\Element' => $qs->getTableName($manager->getClassMetadata('Rapsys\TreeBundle\Entity\Element'), $dp), 'Rapsys\TreeBundle\Entity\Group' => $qs->getTableName($manager->getClassMetadata('Rapsys\TreeBundle\Entity\Group'), $dp), 'Rapsys\TreeBundle\Entity\User' => $qs->getTableName($manager->getClassMetadata('Rapsys\TreeBundle\Entity\User'), $dp), //Set locale