diff --git a/typo3/sysext/scheduler/Classes/ViewHelpers/ModuleLinkViewHelper.php b/typo3/sysext/scheduler/Classes/ViewHelpers/ModuleLinkViewHelper.php deleted file mode 100644 index 7e43d9e0efefa3ed32c99f1ce4e02e53c044ab9c..0000000000000000000000000000000000000000 --- a/typo3/sysext/scheduler/Classes/ViewHelpers/ModuleLinkViewHelper.php +++ /dev/null @@ -1,62 +0,0 @@ -<?php -namespace TYPO3\CMS\Scheduler\ViewHelpers; - -/* - * This file is part of the TYPO3 CMS project. - * - * It is free software; you can redistribute it and/or modify it under - * the terms of the GNU General Public License, either version 2 - * of the License, or any later version. - * - * For the full copyright and license information, please read the - * LICENSE.txt file that was distributed with this source code. - * - * The TYPO3 project - inspiring people to share! - */ - -use TYPO3\CMS\Backend\Routing\UriBuilder; -use TYPO3\CMS\Core\Utility\GeneralUtility; -use TYPO3Fluid\Fluid\Core\Rendering\RenderingContextInterface; -use TYPO3Fluid\Fluid\Core\ViewHelper\AbstractViewHelper; -use TYPO3Fluid\Fluid\Core\ViewHelper\Traits\CompileWithRenderStatic; - -/** - * Create internal link within backend app - * @internal - */ -class ModuleLinkViewHelper extends AbstractViewHelper -{ - use CompileWithRenderStatic; - - /** - * Initializes the arguments - */ - public function initializeArguments() - { - $this->registerArgument('controller', 'string', 'The "controller" of scheduler. Possible values are "scheduler", "check", "info"', true); - $this->registerArgument('action', 'string', 'The action to be called within each controller', true); - $this->registerArgument('arguments', 'array', '', false, []); - } - - /** - * Render module link with command and arguments - * - * @param array $arguments - * @param \Closure $renderChildrenClosure - * @param RenderingContextInterface $renderingContext - * - * @return string - */ - public static function renderStatic(array $arguments, \Closure $renderChildrenClosure, RenderingContextInterface $renderingContext) - { - $moduleArguments = []; - $moduleArguments['SET']['function'] = $arguments['controller']; - $moduleArguments['CMD'] = $arguments['action']; - if (!empty($arguments['arguments'])) { - $moduleArguments['tx_scheduler'] = $arguments['arguments']; - } - - $uriBuilder = GeneralUtility::makeInstance(UriBuilder::class); - return (string)$uriBuilder->buildUriFromRoute('system_txschedulerM1', $moduleArguments); - } -} diff --git a/typo3/sysext/scheduler/Resources/Private/Templates/Backend/SchedulerModule/InfoScreen.html b/typo3/sysext/scheduler/Resources/Private/Templates/Backend/SchedulerModule/InfoScreen.html index 73a3312a75a4cc193936e810c8a0af565c111dcc..b9500fb559d4721dc1c6334bf25ea99ba1f384a4 100644 --- a/typo3/sysext/scheduler/Resources/Private/Templates/Backend/SchedulerModule/InfoScreen.html +++ b/typo3/sysext/scheduler/Resources/Private/Templates/Backend/SchedulerModule/InfoScreen.html @@ -1,4 +1,4 @@ -{namespace s = TYPO3\CMS\Scheduler\ViewHelpers} +<html xmlns:be="http://typo3.org/ns/TYPO3/CMS/Backend/ViewHelpers" data-namespace-typo3-fluid="true"> <p class="lead"> <f:translate key="msg.infoScreenIntro" /> @@ -22,7 +22,7 @@ <f:for each="{registeredClasses}" key="class" as="classInfo"> <tr> <td> - <a href="{s:moduleLink(controller:'scheduler', action: 'add', arguments: '{class: class}')}" title="{f:translate(key:'LLL:EXT:core/Resources/Private/Language/locallang_common.xlf:new')}"> + <a href="{be:moduleLink(route: 'system_txschedulerM1', query: 'SET[function]=scheduler&CMD=add&tx_scheduler[class]={class}')}" title="{f:translate(key:'LLL:EXT:core/Resources/Private/Language/locallang_common.xlf:new')}"> {classInfo.title} </a> </td> @@ -31,7 +31,7 @@ <td> <div class="btn-group" role="group"> <span class="btn btn-default"> - <a href="{s:moduleLink(controller:'scheduler', action: 'add', arguments: '{class: class}')}" title="{f:translate(key:'LLL:EXT:core/Resources/Private/Language/locallang_common.xlf:new')}"> + <a href="{be:moduleLink(route: 'system_txschedulerM1', query: 'SET[function]=scheduler&CMD=add&tx_scheduler[class]={class}')}" title="{f:translate(key:'LLL:EXT:core/Resources/Private/Language/locallang_common.xlf:new')}"> <core:icon identifier="actions-add" /> </a> </span> @@ -42,3 +42,4 @@ </tbody> </table> </div> +</html> \ No newline at end of file