Skip to content
Snippets Groups Projects
Select Git revision
  • 15c8ad2e4d55fb9426a5a6a5aa5ecd3a11d9bdd6
  • master default
  • clement
  • fix_requirements
  • new_signup
  • interface_admin
  • hamza
  • dev
  • test
  • melissa
  • context_sheet
  • sorties_new
  • Seon82-patch-2
  • export_bdd
  • refactor/participation-user-link
15 results

manage.py

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;
        }
    }