Пример #1
0
 /**
  * @param Search $entity
  *
  * @return Builder
  */
 public function addCountry(Search $entity)
 {
     if ($entity->getCountry() instanceof Country) {
         $this->add(function (QueryBuilder $query) use($entity) {
             $query->andWhere('i.country = :country')->setParameter('country', $entity->getCountry()->getId());
         });
     }
     return $this;
 }