getValues(); $this->_getDataObj()->initFromForm($data); return $this; } protected function _getNewForm(array $options = array()) { $options['defaults'] = array('pageId' => Qs_Request::getRequestValue('pageId')); return parent::_getNewForm($options); } protected function _getDefaultLinks() { return $this->_prepareNewLink(parent::_getDefaultLinks()); } protected function _prepareNewLink(array $links) { $links['new'] = array('title' => 'Add New ' . $this->getConfig('itemName')); $links['reorder'] = array('title' => 'Reorder ' . $this->getConfig('itemsName')); if ($pageId = $this->_getDataObj()->getFilter('pageId')) { $links['new']['url'] = $this->url(array( 'action' => 'new', 'pageId' => (int) $pageId )); $links['reorder']['url'] = $this->url(array( 'action' => 'reorder', 'pageId' => (int) $pageId )); } return $links; } protected function _doReorder() { $this->_getDataObj()->setFilter('pageId', Qs_Request::getRequestValue('pageId')); return parent::_doReorder(); } }