]> Raphaƫl G. Git Repositories - airbundle/blobdiff - Repository/SnippetRepository.php
Version 0.6.0
[airbundle] / Repository / SnippetRepository.php
index 3d53487c22901fd3089dd1fd5bee8cb3c3241c2e..c070333962a28f131a4a0779af6cadbc71f9870c 100644 (file)
 
 namespace Rapsys\AirBundle\Repository;
 
 
 namespace Rapsys\AirBundle\Repository;
 
+use Rapsys\AirBundle\Repository;
+
 /**
  * SnippetRepository
  */
 /**
  * SnippetRepository
  */
-class SnippetRepository extends \Doctrine\ORM\EntityRepository {
+class SnippetRepository extends Repository {
        /**
         * Find snippets by user id, locale and index by location id
         *
        /**
         * Find snippets by user id, locale and index by location id
         *
@@ -24,7 +26,7 @@ class SnippetRepository extends \Doctrine\ORM\EntityRepository {
         */
        public function findByUserIdLocaleIndexByLocationId(int $userId, string $locale): array {
                //Fetch snippets
         */
        public function findByUserIdLocaleIndexByLocationId(int $userId, string $locale): array {
                //Fetch snippets
-               $ret = $this->_em
+               $ret = $this->manager
                        ->createQuery('SELECT s FROM Rapsys\AirBundle\Entity\Snippet s INDEX BY s.location WHERE s.locale = :locale and s.user = :user')
                        ->setParameter('user', $userId)
                        ->setParameter('locale', $locale)
                        ->createQuery('SELECT s FROM Rapsys\AirBundle\Entity\Snippet s INDEX BY s.location WHERE s.locale = :locale and s.user = :user')
                        ->setParameter('user', $userId)
                        ->setParameter('locale', $locale)