/** * @inheritdoc */ protected function initColumns() { foreach ($this->_template as $column) { if ($column != 'action') { $this->setupDataColumn($column); } if ($column == 'action') { $this->setupActionColumn(); } } parent::initColumns(); }
protected function initColumns() { parent::initColumns(); if ($this->runInConsoleMode) { array_map(function ($column) { /** @var DataColumn $column */ $column->enableSorting = false; }, $this->columns); } }