Skip to content
Snippets Groups Projects
Select Git revision
  • 6f1f5ee39e02f30b35f83ab88f18c51c49c8bfb3
  • master default
  • goodpaths
  • movie-page
  • front-bilel
  • vieille-branche
  • octofront
  • branche-TP-de-Tom
8 results

users.js

Blame
  • TeamRepository.php 674 B
    <?php
    /**
     * Created by PhpStorm.
     * User: jeremyguiselin
     * Date: 05/12/2016
     * Time: 13:01
     */
    
    namespace BackendBundle\Repository;
    
    use BackendBundle\Entity\Team;
    use Doctrine\ORM\EntityRepository;
    
    /**
     * TeamRepository
     *
     * This class was generated by the Doctrine ORM. Add your own custom
     * repository methods below.
     */
    
    class TeamRepository extends EntityRepository
    {
        public function getAll()
        {
            $qb = $this->createQueryBuilder('t');
            $qb->select('t');
    
            return $qb;
    
        }
    
        public function alreadyExists(Team $pack) : bool
        {
            return $this->findOneBy([
                'name' => $pack->getName()
            ]) !== null;
        }
    }