Add any "WHERE" clause to the builder.

@param  \Illuminate\Database\Query\Builder|\Illuminate\Database\Eloquent\Builder  $builder
@param  mixed  $value
@return \Illuminate\Database\Query\Builder|\Illuminate\Database\Eloquent\Builder
323042
public function handleBuilder($builder, $value)
    {
        // Allow users to overwrite the default "where" clause, e.g. "whereYear"
        $clause = $this->directiveArgValue('clause', 'where');

        return $builder->{$clause}(
            $this->directiveArgValue('key', $this->definitionNode->name->value),
            $operator = $this->directiveArgValue('operator', '='),
            $value
        );
    }
1006494
public function orWhere($column, $operator = null, $value = null)
    {
        return $this->where($column, $operator, $value, 'or');
    }
660719
public function where($column, $operator, $value = null)
    {
        if (is_null($value)) {
            if (is_callable($operator)) {
                $this->where[] = [$column, 'func', $operator];
            } else {
                $this->where[] = [$column, '=', $operator];
            }
        } else {
            $this->where[] = [$column, $operator, $value];
        }

        return $this;
    }
142360
public function where($column, $expression = null, $value = null)
    {
        return $this->doWhere(self::AND_WHERE, $column, $expression, $value);
    }
1165105
public function orWhere($field, $operator = null, $value = null)
    {
        $this->addOrWhere($field, $operator, $value);

        return $this;
    }
503220
public function query() : Builder
	{
		if (! is_null($this->min) && ! is_null($this->max)) {
			$this->builder->whereBetween('price', [$this->min, $this->max]);
		}

		if (! is_null($this->min) && is_null($this->max)) {
			$this->builder->where('price', '>=', $this->min);
		}

		if (is_null($this->min) && ! is_null($this->max)) {
			$this->builder->where('price', '<=', $this->max);
		}

		return $this->builder;
	}
32007
public function orWhere(string $key, string $operator, $value): QueryBuilder
    {
        $this->addWhere($key, $operator, $value, 'OR');
        return $this;
    }
1205730
public function where($key, $value = true, $operator = '=')
    {
        return $this->addCondition($key, $value, $operator, 'where');
    }
600701
protected function whereIn(Builder $query, $where)
    {
        $values = $this->valufy($where['values']);

        return $this->wrap($where['column']).' IN ['.$values.']';
    }
65867
public function apply(Builder $builder) : Builder
    {
        if ($this->hasRequest()) {
            foreach ($this->request as $filter => $value) {
                $this->resolveQueryFor($builder, $filter);
        	}
        }

        return $builder;
    }
410753
public function createFromBuilder(Builder $builder)
    {
        $this->model = $builder->getModel();
        $this->query = $builder;

        $this->build();

        return $this;
    }
1284054
public function orWhereRaw($field, $operator = null, $value = null)
    {
        return $this->where($field, $operator, $value, 'or', true);
    }
884885
public function where($where, $value = null)
    {
        $nArgs = func_num_args();
        if( $nArgs >= 2 ) {
            $this->where[] = array($where, $value);
        } else if( $nArgs >= 1 ) {
            $this->where[] = array($where);
        }
        return $this;
    }
487008
public function where($column, $value = null)
    {
        if (is_array($value)) {
            return $this->whereIn($column, $value);
        }

        if ($column instanceof Closure) {
            return $this->using($column);
        }

        $this->wheres[] = compact('column', 'value');

        return $this;
    }
330737
public function orWhere($column, $expression = null, $value = null)
    {
        return $this->doWhere(self::OR_WHERE, $column, $expression, $value);
    }
464089
public function where($column, $operator, $value = null)
    {
        $instance = $this->whereStrategyInstance();

        $instance->whereStrategy()->where(...func_get_args());

        return $instance;
    }
571950
private function applyWhereClause(Builder $query, $field, $operator, $value, $or = false) {
        $verb = $or ? 'orWhere' : 'where';
        $null_verb = $or ? 'orWhereNull' : 'whereNull';
        $not_null_verb = $or ? 'orWhereNotNull' : 'whereNotNull';

        $value = $this->base64decodeIfNecessary($value);

        switch ($value) {
            case 'today':
                return $query->$verb($field, 'like', Carbon::now()->format('Y-m-d') . '%');
            case 'nottoday':
                return $query->$verb(function ($q) use ($field) {
                    $q->where($field, 'not like', Carbon::now()->format('Y-m-d') . '%')
                        ->orWhereNull($field);
                });
            case 'null':
                return $query->$null_verb($field);
            case 'notnull':
                return $query->$not_null_verb($field);
            default:
                return $query->$verb($field, $operator, $value);
        }
    }