generateMenu(); $this->registerDocheaderButtons(); } } /** * Show the content of the update script (if any). * * @param string $extensionKey Extension key * @throws \TYPO3\CMS\Extensionmanager\Exception\ExtensionManagerException */ public function showAction($extensionKey) { /** @var \TYPO3\CMS\Extensionmanager\Utility\UpdateScriptUtility $updateScriptUtility */ $updateScriptUtility = $this->objectManager->get(\TYPO3\CMS\Extensionmanager\Utility\UpdateScriptUtility::class); $updateScriptResult = $updateScriptUtility->executeUpdateIfNeeded($extensionKey); $this->view ->assign('updateScriptResult', $updateScriptResult) ->assign('extensionKey', $extensionKey); } /** * Registers the Icons into the docheader * * @throws \InvalidArgumentException */ protected function registerDocheaderButtons() { /** @var ButtonBar $buttonBar */ $buttonBar = $this->view->getModuleTemplate()->getDocHeaderComponent()->getButtonBar(); $uriBuilder = $this->controllerContext->getUriBuilder(); $uri = $uriBuilder->reset()->uriFor('index', [], 'List'); $title = $this->translate('extConfTemplate.backToList'); $icon = $this->view->getModuleTemplate()->getIconFactory()->getIcon('actions-view-go-back', Icon::SIZE_SMALL); $button = $buttonBar->makeLinkButton() ->setHref($uri) ->setTitle($title) ->setIcon($icon); $buttonBar->addButton($button, ButtonBar::BUTTON_POSITION_LEFT); } }