src/Grid.php
public function setModel(\atk4\data\Model $model, $columns = null)
    {
        $this->model = $this->table->setModel($model, $columns);

        if ($this->quickSearch && is_array($this->quickSearch)) {
            $this->addQuickSearch($this->quickSearch);
        }

        return $this->model;
    }
public function setModel(\atk4\data\Model $model, $columns = null)
    {
        $this->model = $this->table->setModel($model, $columns);

        if ($this->quickSearch && is_array($this->quickSearch)) {
            $this->addQuickSearch($this->quickSearch);
        }

        return $this->model;
    }
public function setModel ( \ atk4 \ data \ Model $ model , $ columns = null ) { $ this -> model = $ this -> table -> setModel ( $ model , $ columns ) ; if ( $ this -> quickSearch && is_array ( $ this -> quickSearch ) ) { $ this -> addQuickSearch ( $ this -> quickSearch ) ; } return $ this -> model ; }
Sets data Model of Grid.

If $columns is not defined, then automatically will add columns for all
visible model fields. If $columns is set to false, then will not add
columns at all.

@param \atk4\data\Model $m       Data model
@param array|bool       $columns

@return \atk4\data\Model
Sets data Model of Grid .