src/CatLab/Laravel/Database/SelectQueryTransformer.php
protected function processComparison($query, Comparison $comparison)
    {
        $subject = self::translateColumnName($query, $comparison);
        $value = self::translateParameter($query, $comparison->getValue());
        $operator = $comparison->getOperator();

        switch ($operator) {
            case Operator::SEARCH:
                $value = '%' . $value . '%';
                $operator = 'LIKE';
                break;
        }

        $query->where($subject, $operator, $value);
    }
protected function processComparison($query, Comparison $comparison)
    {
        $subject = self::translateColumnName($query, $comparison);
        $value = self::translateParameter($query, $comparison->getValue());
        $operator = $comparison->getOperator();

        switch ($operator) {
            case Operator::SEARCH:
                $value = '%' . $value . '%';
                $operator = 'LIKE';
                break;
        }

        $query->where($subject, $operator, $value);
    }
protected function processComparison ( $ query , Comparison $ comparison ) { $ subject = self :: translateColumnName ( $ query , $ comparison ) ; $ value = self :: translateParameter ( $ query , $ comparison -> getValue ( ) ) ; $ operator = $ comparison -> getOperator ( ) ; switch ( $ operator ) { case Operator :: SEARCH : $ value = '%' . $ value . '%' ; $ operator = 'LIKE' ; break ; } $ query -> where ( $ subject , $ operator , $ value ) ; }
Process a single comparison
@param $query
@param Comparison $comparison
Process a single comparison