Ejemplo n.º 1
0
 /**
  * Creates the module menu object structure from the raw data array
  *
  * @param array $rawModuleData
  * @see class.modulemenu.php getRawModuleData()
  * @return void
  */
 protected function convertRawModuleDataToModuleMenuObject(array $rawModuleData)
 {
     foreach ($rawModuleData as $module) {
         $entry = $this->createEntryFromRawData($module);
         if (isset($module['subitems']) && !empty($module['subitems'])) {
             foreach ($module['subitems'] as $subitem) {
                 $subEntry = $this->createEntryFromRawData($subitem);
                 $entry->addChild($subEntry);
             }
         }
         $this->moduleMenu->attachEntry($entry);
     }
 }
 /**
  * Finds a module menu entry by name
  *
  * @param string $name
  * @return \TYPO3\CMS\Backend\Domain\Model\Module\BackendModule|boolean
  */
 public function findByModuleName($name)
 {
     $entries = $this->moduleMenu->getEntries();
     $entry = $this->findByModuleNameInGivenEntries($name, $entries);
     return $entry;
 }