getConfig('type'); if (Entity::TYPE_AFFILIATE == $type) { $this->_hasFilter = false; $this->_defaultAction = 'affiliateList'; } else if (Entity::TYPE_ASSOCIATE == $type) { $this->_hasFilter = true; $this->_defaultAction = 'associateList'; } else { $this->_do404(); } $dataObj = $this->_getDataObj(); $dataObj->setFilter('type', $type); $dataObj->setFilter('status', Entity::STATUS_ACTIVE); return parent::exec(); } protected function _doAffiliateList() { $this->_initListRedirection(); $item = $this->_getListItem(); $item['tpl'] = $this->getTemplate('affiliate-list.tpl'); $this->_addItem($item); $this->_postList(); return $this; } protected function _doAssociateList() { $this->_addFilterItem(); $this->_initListRedirection(); $item = $this->_getListItem(); $item['tpl'] = $this->getTemplate('associate-list.tpl'); $this->_addItem($item); $this->_postList(); return $this; } }