/** * Get node label * * @access public * @param Varien_Object $node * @return string * @author Ultimate Module Creator */ public function buildNodeName($node) { $result = parent::buildNodeName($node); $result .= '<a target="_blank" href="' . $this->getUrl('adminhtml/cmsextended_cmspage/index', array('id' => $node->getId(), 'clear' => 1)) . '"><em>' . $this->__(' - Edit') . '</em></a>'; return $result; }
/** * Get JSON of a tree node or an associative array * * @access protected * @param Varien_Data_Tree_Node|array $node * @param int $level * @return string * @author Ultimate Module Creator */ protected function _getNodeJson($node, $level = 0) { $item = parent::_getNodeJson($node, $level); if (in_array($node->getId(), $this->getSelectedCmspages())) { $item['checked'] = true; } return $item; }
/** * Returns array with configuration of current node * * @access protected * @param Varien_Data_Tree_Node $node * @param int $level How deep is the node in the tree * @return array * @author Ultimate Module Creator */ protected function _getNodeJson($node, $level = 1) { $item = parent::_getNodeJson($node, $level); if ($this->_isParentSelectedCmspage($node)) { $item['expanded'] = true; } if (in_array($node->getId(), $this->getCmspageIds())) { $item['checked'] = true; } return $item; }