Ejemplo n.º 1
0
 /**
  * {@inheritDoc}
  */
 public function renderMenu($container = null, array $options = [])
 {
     if (!empty($options['id'])) {
         $this->id = (string) $options['id'];
     }
     return parent::renderMenu($container, $options);
 }
Ejemplo n.º 2
0
 public function testRenderDeepestMenuWithPageClassToLi()
 {
     $options = array('addClassToListItem' => true, 'onlyActiveBranch' => true, 'renderParents' => false);
     $pages = $this->_nav2->toArray();
     $pages[1]['class'] = 'foobar';
     $container = new \Zend\Navigation\Navigation($pages);
     $expected = $this->_getExpected('menu/onlyactivebranch_addclasstolistitem.html');
     $actual = $this->_helper->renderMenu($container, $options);
     $this->assertEquals(trim($expected), trim($actual));
 }