public function addSearchCriteria(array $criteria)
    {
        $suffix = $this->getSuffix();
        foreach ($criteria as $crit => $value) {
            if (false === strpos($crit, '.')) {
                $crit = (true === in_array($crit, self::$joinCriteria) ? $this->getSectionAlias() : $this->getAlias()).'.'.$crit;
            }

            $param = str_replace('.', '_', $crit).$suffix;
            $this->andWhere($crit.' IN (:'.$param.')')
                    ->setParameter($param, $value);
        }

        return $this;
    }
public function addSearchCriteria(array $criteria)
    {
        $suffix = $this->getSuffix();
        foreach ($criteria as $crit => $value) {
            if (false === strpos($crit, '.')) {
                $crit = (true === in_array($crit, self::$joinCriteria) ? $this->getSectionAlias() : $this->getAlias()).'.'.$crit;
            }

            $param = str_replace('.', '_', $crit).$suffix;
            $this->andWhere($crit.' IN (:'.$param.')')
                    ->setParameter($param, $value);
        }

        return $this;
    }
public function addSearchCriteria ( array $ criteria ) { $ suffix = $ this -> getSuffix ( ) ; foreach ( $ criteria as $ crit => $ value ) { if ( false === strpos ( $ crit , '.' ) ) { $ crit = ( true === in_array ( $ crit , self :: $ joinCriteria ) ? $ this -> getSectionAlias ( ) : $ this -> getAlias ( ) ) . '.' . $ crit ; } $ param = str_replace ( '.' , '_' , $ crit ) . $ suffix ; $ this -> andWhere ( $ crit . ' IN (:' . $ param . ')' ) -> setParameter ( $ param , $ value ) ; } return $ this ; }
Add query part to math provided criteria.

@param  array                $criteria           Array of criteria to look for( ['field' => 'value'] )

@return PageQueryBuilder
Add query part to math provided criteria .