protected function fetchData() { if (!is_null($this->_cache_duration)) { $this->model = $this->model->cache($this->_cache_duration, $this->_cache_dependency, 2); } return parent::fetchData(); }
/** * Fetches the data from the persistent data storage. * @return array list of data items */ protected function fetchData() { $data = parent::fetchData(); foreach ($data as $model) { $this->_authorizer->attachUserBehavior($model); } return $data; }
/** * Fetches the data from the persistent data storage. * @return array list of data items */ public function fetchData() { $data = parent::fetchData(); if ($this->_behaviors !== array()) { foreach ($data as $model) { $model->attachBehaviors($this->_behaviors); } } return $data; }
/** * Fetches the data from the persistent data storage. * * @return array list of data items */ protected function fetchData() { $sourceCriteria = clone $this->getCriteria(); $criteria = $this->getCriteria(); if (($alphapagination = $this->getAlphaPagination()) !== false) { $alphapagination->applyCondition($criteria); } $result = parent::fetchData(); $this->setCriteria($sourceCriteria); return $result; }
/** * Fetches the data from the persistent data storage. * Additionally, calls KeenActiveDataProvider::afterFetch method * @return array list of data items */ protected function fetchData() { if ($this->_withKeenLoading) { $this->_prepareKeenLoading(); } $data = parent::fetchData(); if ($data && $this->_withKeenLoading) { $data = $this->afterFetch($data); } return $data; }