yii\db\QueryTrait::andWhere PHP Method

andWhere() public method

The new condition and the existing one will be joined using the 'AND' operator.
See also: where()
See also: orWhere()
public andWhere ( string | array $condition )
$condition string | array the new WHERE condition. Please refer to [[where()]] on how to specify this parameter.
    public function andWhere($condition)
    {
        if ($this->where === null) {
            $this->where = $condition;
        } else {
            $this->where = ['and', $this->where, $condition];
        }
        return $this;
    }