diff --git a/typo3/sysext/core/Documentation/Changelog/master/Breaking-91066-MovedInterfacesOfDashboard.rst b/typo3/sysext/core/Documentation/Changelog/master/Breaking-91066-MovedInterfacesOfDashboard.rst new file mode 100644 index 0000000000000000000000000000000000000000..b026608e8c25b9a7ad0909eb1a337014ed9f129d --- /dev/null +++ b/typo3/sysext/core/Documentation/Changelog/master/Breaking-91066-MovedInterfacesOfDashboard.rst @@ -0,0 +1,43 @@ +.. include:: ../../Includes.txt + +=============================================== +Breaking: #91066 - Move interfaces of Dashboard +=============================================== + +See :issue:`91066` + +Description +=========== +The interfaces of the dashboard have been moved out of the +interfaces folder to be consistent with the overall TYPO3 structure. + +Impact +====== +New widget types have implemented one or more of the interfaces of EXT:dashboard. +If the namespace of those interfaces is not changed, you will get errors saying +that the old interfaces are not found anymore. + +Affected Installations +====================== +All 3rd party extensions that created own widget types and implements one of the +interfaces of EXT:dashboard should update their paths. The accected interfaces +are: + +- :php:`AdditionalCssInterface` +- :php:`AdditionalJavascriptInterface` +- :php:`ButtonProviderInterface` +- :php:`ChartDataProviderInterface` +- :php:`EventDataProviderInterface` +- :php:`ListDataProviderInterface` +- :php:`NumberWithIconDataProviderInterface` +- :php:`RequireJsModuleInterface` +- :php:`WidgetConfigurationInterface` +- :php:`WidgetInterface` + +Migration +========= +The interfaces above has been moved from :php:`TYPO3\CMS\Dashboard\Widgets\Interfaces` +to :php:`TYPO3\CMS\Dashboard\Widgets`. You need to alter the namespaces of those +interfaces in your own widgets. + +.. index:: Backend, ext:dashboard, FullyScanned diff --git a/typo3/sysext/core/Documentation/Changelog/master/Breaking-91066-RemovedButtonUtility.rst b/typo3/sysext/core/Documentation/Changelog/master/Breaking-91066-RemovedButtonUtility.rst new file mode 100644 index 0000000000000000000000000000000000000000..61b9d8420268e25979b3827cca7292700b5b0b72 --- /dev/null +++ b/typo3/sysext/core/Documentation/Changelog/master/Breaking-91066-RemovedButtonUtility.rst @@ -0,0 +1,56 @@ +.. include:: ../../Includes.txt + +======================================== +Breaking: #91066 - Removed ButtonUtility +======================================== + +See :issue:`91066` + +Description +=========== +The ButtonUtility was superfluous and therefor removed. + +Impact +====== +You need to remove the usage of the :php:`ButtonUtility` class, otherwise you +will get fatal errors of missing classes. + +Affected Installations +====================== +All 3rd party extensions that created own widget types with the option to add +a button using the :php:`ButtonUtility::generateButtonConfig()` method are +affected. + +Migration +========= +First of all you need to change one line in your Widget class. When assigning +your button parameter to your Fluid Template, you most probably have the following +line: + +.. code-block:: php + + 'button' => ButtonUtility::generateButtonConfig($this->buttonProvider), + +You have to change that into: + +.. code-block:: php + + 'button' => $this->buttonProvider, + +Because you change the variable passed to your template, you also need to do a +small change in your template. + +In your template in the footer section, you will find a line like this: + +.. code-block:: html + + <a href="{button.link}" target="{button.target}" class="widget-cta">{f:translate(id: button.text, default: button.text)}</a> + +You need to change the text property to the title property. So the line above will +become: + +.. code-block:: html + + <a href="{button.link}" target="{button.target}" class="widget-cta">{f:translate(id: button.title, default: button.title)}</a> + +.. index:: Backend, ext:dashboard, FullyScanned diff --git a/typo3/sysext/dashboard/Classes/Controller/WidgetAjaxController.php b/typo3/sysext/dashboard/Classes/Controller/WidgetAjaxController.php index 598daf02e939352e95e8387aa4dd9042ebbe338f..c2ac0d4596688ea7b4e1d4c3a4b0ac8c2e136f2f 100644 --- a/typo3/sysext/dashboard/Classes/Controller/WidgetAjaxController.php +++ b/typo3/sysext/dashboard/Classes/Controller/WidgetAjaxController.php @@ -23,8 +23,8 @@ use TYPO3\CMS\Core\Http\JsonResponse; use TYPO3\CMS\Dashboard\Dashboard; use TYPO3\CMS\Dashboard\DashboardRepository; use TYPO3\CMS\Dashboard\WidgetRegistry; -use TYPO3\CMS\Dashboard\Widgets\Interfaces\EventDataInterface; -use TYPO3\CMS\Dashboard\Widgets\Interfaces\WidgetInterface; +use TYPO3\CMS\Dashboard\Widgets\EventDataInterface; +use TYPO3\CMS\Dashboard\Widgets\WidgetInterface; class WidgetAjaxController extends AbstractController { diff --git a/typo3/sysext/dashboard/Classes/Dashboard.php b/typo3/sysext/dashboard/Classes/Dashboard.php index 2e5691073ced219e9a3113e4eedfa2d2b3c8e62e..b2273f5f5c6a2f8f4b860b27dd09f24af556bbeb 100644 --- a/typo3/sysext/dashboard/Classes/Dashboard.php +++ b/typo3/sysext/dashboard/Classes/Dashboard.php @@ -19,8 +19,8 @@ namespace TYPO3\CMS\Dashboard; use Psr\Container\ContainerInterface; use TYPO3\CMS\Core\Localization\LanguageService; -use TYPO3\CMS\Dashboard\Widgets\Interfaces\WidgetConfigurationInterface; -use TYPO3\CMS\Dashboard\Widgets\Interfaces\WidgetInterface; +use TYPO3\CMS\Dashboard\Widgets\WidgetConfigurationInterface; +use TYPO3\CMS\Dashboard\Widgets\WidgetInterface; class Dashboard { diff --git a/typo3/sysext/dashboard/Classes/DashboardInitializationService.php b/typo3/sysext/dashboard/Classes/DashboardInitializationService.php index 1655f3147165573815be98caafb68ee9b84c61cb..3cc0895e0e5a4a8b8baefd9fc0e5b75881a928b2 100644 --- a/typo3/sysext/dashboard/Classes/DashboardInitializationService.php +++ b/typo3/sysext/dashboard/Classes/DashboardInitializationService.php @@ -20,9 +20,9 @@ namespace TYPO3\CMS\Dashboard; use TYPO3\CMS\Core\Authentication\BackendUserAuthentication; use TYPO3\CMS\Core\Utility\GeneralUtility; use TYPO3\CMS\Core\Utility\PathUtility; -use TYPO3\CMS\Dashboard\Widgets\Interfaces\AdditionalCssInterface; -use TYPO3\CMS\Dashboard\Widgets\Interfaces\AdditionalJavaScriptInterface; -use TYPO3\CMS\Dashboard\Widgets\Interfaces\RequireJsModuleInterface; +use TYPO3\CMS\Dashboard\Widgets\AdditionalCssInterface; +use TYPO3\CMS\Dashboard\Widgets\AdditionalJavaScriptInterface; +use TYPO3\CMS\Dashboard\Widgets\RequireJsModuleInterface; class DashboardInitializationService { diff --git a/typo3/sysext/dashboard/Classes/DashboardRepository.php b/typo3/sysext/dashboard/Classes/DashboardRepository.php index b1067ae91d753681bb6c7175ca609912fe3226da..152ab41b461eb35c8a35599df2f49ac9a58b472f 100644 --- a/typo3/sysext/dashboard/Classes/DashboardRepository.php +++ b/typo3/sysext/dashboard/Classes/DashboardRepository.php @@ -22,7 +22,7 @@ use Psr\Container\ContainerInterface; use TYPO3\CMS\Core\Database\ConnectionPool; use TYPO3\CMS\Core\Database\Query\QueryBuilder; use TYPO3\CMS\Core\Utility\GeneralUtility; -use TYPO3\CMS\Dashboard\Widgets\Interfaces\WidgetInterface; +use TYPO3\CMS\Dashboard\Widgets\WidgetInterface; class DashboardRepository { diff --git a/typo3/sysext/dashboard/Classes/Utility/ButtonUtility.php b/typo3/sysext/dashboard/Classes/Utility/ButtonUtility.php deleted file mode 100644 index 6ab53c5d0f8acf94c394b588054d01c1a7383343..0000000000000000000000000000000000000000 --- a/typo3/sysext/dashboard/Classes/Utility/ButtonUtility.php +++ /dev/null @@ -1,36 +0,0 @@ -<?php - -declare(strict_types=1); - -/* - * 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! - */ - -namespace TYPO3\CMS\Dashboard\Utility; - -use TYPO3\CMS\Dashboard\Widgets\Interfaces\ButtonProviderInterface; - -class ButtonUtility -{ - public static function generateButtonConfig(?ButtonProviderInterface $buttonProvider): array - { - if ($buttonProvider instanceof ButtonProviderInterface && $buttonProvider->getTitle() && $buttonProvider->getLink()) { - return [ - 'text' => $buttonProvider->getTitle(), - 'link' => $buttonProvider->getLink(), - 'target' => $buttonProvider->getTarget(), - ]; - } - - return []; - } -} diff --git a/typo3/sysext/dashboard/Classes/WidgetRegistry.php b/typo3/sysext/dashboard/Classes/WidgetRegistry.php index 27d0c9101cb8f1ceb63fd6d904ef400d290f3133..d7ea59835fc2191426e88feeaabc60983a92ad12 100644 --- a/typo3/sysext/dashboard/Classes/WidgetRegistry.php +++ b/typo3/sysext/dashboard/Classes/WidgetRegistry.php @@ -21,7 +21,7 @@ use Psr\Container\ContainerInterface; use TYPO3\CMS\Core\Authentication\BackendUserAuthentication; use TYPO3\CMS\Core\SingletonInterface; use TYPO3\CMS\Core\Utility\ArrayUtility; -use TYPO3\CMS\Dashboard\Widgets\Interfaces\WidgetInterface; +use TYPO3\CMS\Dashboard\Widgets\WidgetInterface; class WidgetRegistry implements SingletonInterface { diff --git a/typo3/sysext/dashboard/Classes/Widgets/Interfaces/AdditionalCssInterface.php b/typo3/sysext/dashboard/Classes/Widgets/AdditionalCssInterface.php similarity index 94% rename from typo3/sysext/dashboard/Classes/Widgets/Interfaces/AdditionalCssInterface.php rename to typo3/sysext/dashboard/Classes/Widgets/AdditionalCssInterface.php index 0d539f3f935940023f128729951acb07ee2319c2..e930ecf3d8e0e63a07d1c6d17015b4bb475eb495 100644 --- a/typo3/sysext/dashboard/Classes/Widgets/Interfaces/AdditionalCssInterface.php +++ b/typo3/sysext/dashboard/Classes/Widgets/AdditionalCssInterface.php @@ -15,7 +15,7 @@ declare(strict_types=1); * The TYPO3 project - inspiring people to share! */ -namespace TYPO3\CMS\Dashboard\Widgets\Interfaces; +namespace TYPO3\CMS\Dashboard\Widgets; /** * In case a widget should provide additional CSS files, the widget must implement this interface. diff --git a/typo3/sysext/dashboard/Classes/Widgets/Interfaces/AdditionalJavaScriptInterface.php b/typo3/sysext/dashboard/Classes/Widgets/AdditionalJavaScriptInterface.php similarity index 94% rename from typo3/sysext/dashboard/Classes/Widgets/Interfaces/AdditionalJavaScriptInterface.php rename to typo3/sysext/dashboard/Classes/Widgets/AdditionalJavaScriptInterface.php index c950d0b887546d8ebf15d3bc5b4ed789f21412af..b340ebdc558eaafadfe9df9d23f83a9652aa3ac4 100644 --- a/typo3/sysext/dashboard/Classes/Widgets/Interfaces/AdditionalJavaScriptInterface.php +++ b/typo3/sysext/dashboard/Classes/Widgets/AdditionalJavaScriptInterface.php @@ -15,7 +15,7 @@ declare(strict_types=1); * The TYPO3 project - inspiring people to share! */ -namespace TYPO3\CMS\Dashboard\Widgets\Interfaces; +namespace TYPO3\CMS\Dashboard\Widgets; /** * In case a widget should provide additional JavaScript files, the widget must implement this interface. diff --git a/typo3/sysext/dashboard/Classes/Widgets/BarChartWidget.php b/typo3/sysext/dashboard/Classes/Widgets/BarChartWidget.php index a597cc6b551bebe471c69d7dfb990f9aa089c831..09007db2306daa12e1670480f3128d30bc118687 100644 --- a/typo3/sysext/dashboard/Classes/Widgets/BarChartWidget.php +++ b/typo3/sysext/dashboard/Classes/Widgets/BarChartWidget.php @@ -17,14 +17,6 @@ declare(strict_types=1); namespace TYPO3\CMS\Dashboard\Widgets; -use TYPO3\CMS\Dashboard\Utility\ButtonUtility; -use TYPO3\CMS\Dashboard\Widgets\Interfaces\AdditionalCssInterface; -use TYPO3\CMS\Dashboard\Widgets\Interfaces\ButtonProviderInterface; -use TYPO3\CMS\Dashboard\Widgets\Interfaces\ChartDataProviderInterface; -use TYPO3\CMS\Dashboard\Widgets\Interfaces\EventDataInterface; -use TYPO3\CMS\Dashboard\Widgets\Interfaces\RequireJsModuleInterface; -use TYPO3\CMS\Dashboard\Widgets\Interfaces\WidgetConfigurationInterface; -use TYPO3\CMS\Dashboard\Widgets\Interfaces\WidgetInterface; use TYPO3\CMS\Fluid\View\StandaloneView; /** @@ -83,7 +75,7 @@ class BarChartWidget implements WidgetInterface, EventDataInterface, AdditionalC { $this->view->setTemplate('Widget/ChartWidget'); $this->view->assignMultiple([ - 'button' => ButtonUtility::generateButtonConfig($this->buttonProvider), + 'button' => $this->buttonProvider, 'options' => $this->options, 'configuration' => $this->configuration, ]); diff --git a/typo3/sysext/dashboard/Classes/Widgets/Interfaces/ButtonProviderInterface.php b/typo3/sysext/dashboard/Classes/Widgets/ButtonProviderInterface.php similarity index 96% rename from typo3/sysext/dashboard/Classes/Widgets/Interfaces/ButtonProviderInterface.php rename to typo3/sysext/dashboard/Classes/Widgets/ButtonProviderInterface.php index 4b03239bccd8c13ad5181c6271581f03acd2ad80..18c14949dfe1e4f01b5ef0a9da69b93ae0e527c0 100644 --- a/typo3/sysext/dashboard/Classes/Widgets/Interfaces/ButtonProviderInterface.php +++ b/typo3/sysext/dashboard/Classes/Widgets/ButtonProviderInterface.php @@ -15,7 +15,7 @@ declare(strict_types=1); * The TYPO3 project - inspiring people to share! */ -namespace TYPO3\CMS\Dashboard\Widgets\Interfaces; +namespace TYPO3\CMS\Dashboard\Widgets; /** * In case a widget should have a button in the footer of the widget, this button must implement this interface. diff --git a/typo3/sysext/dashboard/Classes/Widgets/Interfaces/ChartDataProviderInterface.php b/typo3/sysext/dashboard/Classes/Widgets/ChartDataProviderInterface.php similarity index 95% rename from typo3/sysext/dashboard/Classes/Widgets/Interfaces/ChartDataProviderInterface.php rename to typo3/sysext/dashboard/Classes/Widgets/ChartDataProviderInterface.php index 747d81cf43e63bc1e715486cf1957526b5e2b049..631f5d12dc4e4cb5128d8ef70c27e8e04f7c1c0c 100644 --- a/typo3/sysext/dashboard/Classes/Widgets/Interfaces/ChartDataProviderInterface.php +++ b/typo3/sysext/dashboard/Classes/Widgets/ChartDataProviderInterface.php @@ -15,7 +15,7 @@ declare(strict_types=1); * The TYPO3 project - inspiring people to share! */ -namespace TYPO3\CMS\Dashboard\Widgets\Interfaces; +namespace TYPO3\CMS\Dashboard\Widgets; /** * Defines API for provider, used for chart widgets. diff --git a/typo3/sysext/dashboard/Classes/Widgets/CtaWidget.php b/typo3/sysext/dashboard/Classes/Widgets/CtaWidget.php index b8e0918b2f319a7d0f361be3224fc201880e671b..bfb3c252d7e5cf501e9b051e9d089fa5bb122ba6 100644 --- a/typo3/sysext/dashboard/Classes/Widgets/CtaWidget.php +++ b/typo3/sysext/dashboard/Classes/Widgets/CtaWidget.php @@ -17,10 +17,6 @@ declare(strict_types=1); namespace TYPO3\CMS\Dashboard\Widgets; -use TYPO3\CMS\Dashboard\Utility\ButtonUtility; -use TYPO3\CMS\Dashboard\Widgets\Interfaces\ButtonProviderInterface; -use TYPO3\CMS\Dashboard\Widgets\Interfaces\WidgetConfigurationInterface; -use TYPO3\CMS\Dashboard\Widgets\Interfaces\WidgetInterface; use TYPO3\CMS\Fluid\View\StandaloneView; /** @@ -75,7 +71,7 @@ class CtaWidget implements WidgetInterface $this->view->assignMultiple([ 'text' => $this->options['text'], 'options' => $this->options, - 'button' => ButtonUtility::generateButtonConfig($this->buttonProvider), + 'button' => $this->buttonProvider, 'configuration' => $this->configuration ]); return $this->view->render(); diff --git a/typo3/sysext/dashboard/Classes/Widgets/DoughnutChartWidget.php b/typo3/sysext/dashboard/Classes/Widgets/DoughnutChartWidget.php index a43a3c107d9a91d94ad5fb035309da4451532395..fb04a58aebfd0e4ff1899f6a827a6a6d4a682d75 100644 --- a/typo3/sysext/dashboard/Classes/Widgets/DoughnutChartWidget.php +++ b/typo3/sysext/dashboard/Classes/Widgets/DoughnutChartWidget.php @@ -17,14 +17,6 @@ declare(strict_types=1); namespace TYPO3\CMS\Dashboard\Widgets; -use TYPO3\CMS\Dashboard\Utility\ButtonUtility; -use TYPO3\CMS\Dashboard\Widgets\Interfaces\AdditionalCssInterface; -use TYPO3\CMS\Dashboard\Widgets\Interfaces\ButtonProviderInterface; -use TYPO3\CMS\Dashboard\Widgets\Interfaces\ChartDataProviderInterface; -use TYPO3\CMS\Dashboard\Widgets\Interfaces\EventDataInterface; -use TYPO3\CMS\Dashboard\Widgets\Interfaces\RequireJsModuleInterface; -use TYPO3\CMS\Dashboard\Widgets\Interfaces\WidgetConfigurationInterface; -use TYPO3\CMS\Dashboard\Widgets\Interfaces\WidgetInterface; use TYPO3\CMS\Fluid\View\StandaloneView; /** @@ -83,7 +75,7 @@ class DoughnutChartWidget implements WidgetInterface, EventDataInterface, Additi { $this->view->setTemplate('Widget/ChartWidget'); $this->view->assignMultiple([ - 'button' => ButtonUtility::generateButtonConfig($this->buttonProvider), + 'button' => $this->buttonProvider, 'options' => $this->options, 'configuration' => $this->configuration, ]); diff --git a/typo3/sysext/dashboard/Classes/Widgets/Interfaces/EventDataInterface.php b/typo3/sysext/dashboard/Classes/Widgets/EventDataInterface.php similarity index 94% rename from typo3/sysext/dashboard/Classes/Widgets/Interfaces/EventDataInterface.php rename to typo3/sysext/dashboard/Classes/Widgets/EventDataInterface.php index bac3a9669fc5f3978ffb0289be6e6d20212d518b..03a9fbf9b50fa6676d51988a59c2aad3f18a7e29 100644 --- a/typo3/sysext/dashboard/Classes/Widgets/Interfaces/EventDataInterface.php +++ b/typo3/sysext/dashboard/Classes/Widgets/EventDataInterface.php @@ -15,7 +15,7 @@ declare(strict_types=1); * The TYPO3 project - inspiring people to share! */ -namespace TYPO3\CMS\Dashboard\Widgets\Interfaces; +namespace TYPO3\CMS\Dashboard\Widgets; /** * In case a widget should provide additional data as JSON payload, the widget must implement this interface. diff --git a/typo3/sysext/dashboard/Classes/Widgets/Interfaces/ListDataProviderInterface.php b/typo3/sysext/dashboard/Classes/Widgets/ListDataProviderInterface.php similarity index 94% rename from typo3/sysext/dashboard/Classes/Widgets/Interfaces/ListDataProviderInterface.php rename to typo3/sysext/dashboard/Classes/Widgets/ListDataProviderInterface.php index 01945a88ba8e09c969a17333246cb75240b72cd6..86d9c62a00eb64fa79e2d9984f500e53689675ef 100644 --- a/typo3/sysext/dashboard/Classes/Widgets/Interfaces/ListDataProviderInterface.php +++ b/typo3/sysext/dashboard/Classes/Widgets/ListDataProviderInterface.php @@ -15,7 +15,7 @@ declare(strict_types=1); * The TYPO3 project - inspiring people to share! */ -namespace TYPO3\CMS\Dashboard\Widgets\Interfaces; +namespace TYPO3\CMS\Dashboard\Widgets; /** * The dataprovider of a ListWidget, should implement this interface diff --git a/typo3/sysext/dashboard/Classes/Widgets/ListWidget.php b/typo3/sysext/dashboard/Classes/Widgets/ListWidget.php index 09eb2ede5001a97768edb24b154b10e68f23a49f..2622d0c4db07fd893b8da28b79fe741b365373ec 100644 --- a/typo3/sysext/dashboard/Classes/Widgets/ListWidget.php +++ b/typo3/sysext/dashboard/Classes/Widgets/ListWidget.php @@ -17,11 +17,6 @@ declare(strict_types=1); namespace TYPO3\CMS\Dashboard\Widgets; -use TYPO3\CMS\Dashboard\Utility\ButtonUtility; -use TYPO3\CMS\Dashboard\Widgets\Interfaces\ButtonProviderInterface; -use TYPO3\CMS\Dashboard\Widgets\Interfaces\ListDataProviderInterface; -use TYPO3\CMS\Dashboard\Widgets\Interfaces\WidgetConfigurationInterface; -use TYPO3\CMS\Dashboard\Widgets\Interfaces\WidgetInterface; use TYPO3\CMS\Fluid\View\StandaloneView; /** @@ -81,7 +76,7 @@ class ListWidget implements WidgetInterface $this->view->assignMultiple([ 'items' => $this->getItems(), 'options' => $this->options, - 'button' => ButtonUtility::generateButtonConfig($this->buttonProvider), + 'button' => $this->buttonProvider, 'configuration' => $this->configuration, ]); return $this->view->render(); diff --git a/typo3/sysext/dashboard/Classes/Widgets/Interfaces/NumberWithIconDataProviderInterface.php b/typo3/sysext/dashboard/Classes/Widgets/NumberWithIconDataProviderInterface.php similarity index 93% rename from typo3/sysext/dashboard/Classes/Widgets/Interfaces/NumberWithIconDataProviderInterface.php rename to typo3/sysext/dashboard/Classes/Widgets/NumberWithIconDataProviderInterface.php index c15ec1b0cb03207222d9b59faaa4f195ee02bb30..51371a48d01433acb19a48ee0f45d5cbf3b1cb64 100644 --- a/typo3/sysext/dashboard/Classes/Widgets/Interfaces/NumberWithIconDataProviderInterface.php +++ b/typo3/sysext/dashboard/Classes/Widgets/NumberWithIconDataProviderInterface.php @@ -15,7 +15,7 @@ declare(strict_types=1); * The TYPO3 project - inspiring people to share! */ -namespace TYPO3\CMS\Dashboard\Widgets\Interfaces; +namespace TYPO3\CMS\Dashboard\Widgets; /** * The dataprovider of a NumberWithIcon widget should implement this interface diff --git a/typo3/sysext/dashboard/Classes/Widgets/NumberWithIconWidget.php b/typo3/sysext/dashboard/Classes/Widgets/NumberWithIconWidget.php index 2f1c46fab17cfb08edf0ed68af82013d8b591f8c..63d80de1e5ffcf905804a787e0a7ec528d60559c 100644 --- a/typo3/sysext/dashboard/Classes/Widgets/NumberWithIconWidget.php +++ b/typo3/sysext/dashboard/Classes/Widgets/NumberWithIconWidget.php @@ -17,9 +17,6 @@ declare(strict_types=1); namespace TYPO3\CMS\Dashboard\Widgets; -use TYPO3\CMS\Dashboard\Widgets\Interfaces\NumberWithIconDataProviderInterface; -use TYPO3\CMS\Dashboard\Widgets\Interfaces\WidgetConfigurationInterface; -use TYPO3\CMS\Dashboard\Widgets\Interfaces\WidgetInterface; use TYPO3\CMS\Fluid\View\StandaloneView; /** diff --git a/typo3/sysext/dashboard/Classes/Widgets/Provider/ButtonProvider.php b/typo3/sysext/dashboard/Classes/Widgets/Provider/ButtonProvider.php index 84e0494c25634462942a18bbfb04ddaca2175c4b..145f19eac77befc2f153d206834300987167605d 100644 --- a/typo3/sysext/dashboard/Classes/Widgets/Provider/ButtonProvider.php +++ b/typo3/sysext/dashboard/Classes/Widgets/Provider/ButtonProvider.php @@ -17,7 +17,7 @@ declare(strict_types=1); namespace TYPO3\CMS\Dashboard\Widgets\Provider; -use TYPO3\CMS\Dashboard\Widgets\Interfaces\ButtonProviderInterface; +use TYPO3\CMS\Dashboard\Widgets\ButtonProviderInterface; /** * Provide link for sys log button. diff --git a/typo3/sysext/dashboard/Classes/Widgets/Provider/NumberOfFailedLoginsDataProvider.php b/typo3/sysext/dashboard/Classes/Widgets/Provider/NumberOfFailedLoginsDataProvider.php index 1ef38bc2848bcd54a3d09c41fbaabc89b0cb53dd..84970760eb096cd8a81b851d3a56214ed8d5257c 100644 --- a/typo3/sysext/dashboard/Classes/Widgets/Provider/NumberOfFailedLoginsDataProvider.php +++ b/typo3/sysext/dashboard/Classes/Widgets/Provider/NumberOfFailedLoginsDataProvider.php @@ -23,7 +23,7 @@ use TYPO3\CMS\Core\SysLog\Action\Login as SystemLogLoginAction; use TYPO3\CMS\Core\SysLog\Error as SystemLogErrorClassification; use TYPO3\CMS\Core\SysLog\Type as SystemLogType; use TYPO3\CMS\Core\Utility\GeneralUtility; -use TYPO3\CMS\Dashboard\Widgets\Interfaces\NumberWithIconDataProviderInterface; +use TYPO3\CMS\Dashboard\Widgets\NumberWithIconDataProviderInterface; class NumberOfFailedLoginsDataProvider implements NumberWithIconDataProviderInterface { diff --git a/typo3/sysext/dashboard/Classes/Widgets/Provider/SysLogButtonProvider.php b/typo3/sysext/dashboard/Classes/Widgets/Provider/SysLogButtonProvider.php index 2f0441d4fa9dcd816fc9e909523f9069d21e9fde..ae32103dd6e679be64e43259bd637eb7f9952174 100644 --- a/typo3/sysext/dashboard/Classes/Widgets/Provider/SysLogButtonProvider.php +++ b/typo3/sysext/dashboard/Classes/Widgets/Provider/SysLogButtonProvider.php @@ -20,7 +20,7 @@ namespace TYPO3\CMS\Dashboard\Widgets\Provider; use TYPO3\CMS\Backend\Routing\UriBuilder; use TYPO3\CMS\Core\Utility\ExtensionManagementUtility; use TYPO3\CMS\Core\Utility\GeneralUtility; -use TYPO3\CMS\Dashboard\Widgets\Interfaces\ButtonProviderInterface; +use TYPO3\CMS\Dashboard\Widgets\ButtonProviderInterface; /** * Provide link for sys log button. diff --git a/typo3/sysext/dashboard/Classes/Widgets/Provider/SysLogErrorsDataProvider.php b/typo3/sysext/dashboard/Classes/Widgets/Provider/SysLogErrorsDataProvider.php index 9e4666690540ba57897b59a3140d201cf44b32a8..9a5349b99439d319853cec4aaf73a7a8da4c9bac 100644 --- a/typo3/sysext/dashboard/Classes/Widgets/Provider/SysLogErrorsDataProvider.php +++ b/typo3/sysext/dashboard/Classes/Widgets/Provider/SysLogErrorsDataProvider.php @@ -23,7 +23,7 @@ use TYPO3\CMS\Core\Localization\LanguageService; use TYPO3\CMS\Core\SysLog\Type as SystemLogType; use TYPO3\CMS\Core\Utility\GeneralUtility; use TYPO3\CMS\Dashboard\WidgetApi; -use TYPO3\CMS\Dashboard\Widgets\Interfaces\ChartDataProviderInterface; +use TYPO3\CMS\Dashboard\Widgets\ChartDataProviderInterface; /** * Provides chart data for sys log errors. diff --git a/typo3/sysext/dashboard/Classes/Widgets/Provider/TypeOfUsersChartDataProvider.php b/typo3/sysext/dashboard/Classes/Widgets/Provider/TypeOfUsersChartDataProvider.php index 5392ab9117334e8a36b80a2fb2ffe43b2cd1ac4b..b34c6d22487508748ca53e2a66888b37c3dfe837 100644 --- a/typo3/sysext/dashboard/Classes/Widgets/Provider/TypeOfUsersChartDataProvider.php +++ b/typo3/sysext/dashboard/Classes/Widgets/Provider/TypeOfUsersChartDataProvider.php @@ -22,7 +22,7 @@ use TYPO3\CMS\Core\Database\ConnectionPool; use TYPO3\CMS\Core\Localization\LanguageService; use TYPO3\CMS\Core\Utility\GeneralUtility; use TYPO3\CMS\Dashboard\WidgetApi; -use TYPO3\CMS\Dashboard\Widgets\Interfaces\ChartDataProviderInterface; +use TYPO3\CMS\Dashboard\Widgets\ChartDataProviderInterface; class TypeOfUsersChartDataProvider implements ChartDataProviderInterface { diff --git a/typo3/sysext/dashboard/Classes/Widgets/Interfaces/RequireJsModuleInterface.php b/typo3/sysext/dashboard/Classes/Widgets/RequireJsModuleInterface.php similarity index 94% rename from typo3/sysext/dashboard/Classes/Widgets/Interfaces/RequireJsModuleInterface.php rename to typo3/sysext/dashboard/Classes/Widgets/RequireJsModuleInterface.php index 30a69d50aa591e38d28a8c87efb16e4e2206c94a..c1f9a93841a4f473df5e271035af17ececcf183e 100644 --- a/typo3/sysext/dashboard/Classes/Widgets/Interfaces/RequireJsModuleInterface.php +++ b/typo3/sysext/dashboard/Classes/Widgets/RequireJsModuleInterface.php @@ -15,7 +15,7 @@ declare(strict_types=1); * The TYPO3 project - inspiring people to share! */ -namespace TYPO3\CMS\Dashboard\Widgets\Interfaces; +namespace TYPO3\CMS\Dashboard\Widgets; /** * In case a widget should provide additional requireJS modules, the widget must implement this interface. diff --git a/typo3/sysext/dashboard/Classes/Widgets/RssWidget.php b/typo3/sysext/dashboard/Classes/Widgets/RssWidget.php index 7870bf5296b3a92058ff2047a70476b2e46da46b..bd1eea1a952b32257dcbb2643e1511664cde6ded 100644 --- a/typo3/sysext/dashboard/Classes/Widgets/RssWidget.php +++ b/typo3/sysext/dashboard/Classes/Widgets/RssWidget.php @@ -19,10 +19,6 @@ namespace TYPO3\CMS\Dashboard\Widgets; use TYPO3\CMS\Core\Cache\Frontend\FrontendInterface as Cache; use TYPO3\CMS\Core\Utility\GeneralUtility; -use TYPO3\CMS\Dashboard\Utility\ButtonUtility; -use TYPO3\CMS\Dashboard\Widgets\Interfaces\ButtonProviderInterface; -use TYPO3\CMS\Dashboard\Widgets\Interfaces\WidgetConfigurationInterface; -use TYPO3\CMS\Dashboard\Widgets\Interfaces\WidgetInterface; use TYPO3\CMS\Fluid\View\StandaloneView; /** @@ -92,7 +88,7 @@ class RssWidget implements WidgetInterface $this->view->assignMultiple([ 'items' => $this->getRssItems(), 'options' => $this->options, - 'button' => ButtonUtility::generateButtonConfig($this->buttonProvider), + 'button' => $this->buttonProvider, 'configuration' => $this->configuration, ]); return $this->view->render(); diff --git a/typo3/sysext/dashboard/Classes/Widgets/T3GeneralInformationWidget.php b/typo3/sysext/dashboard/Classes/Widgets/T3GeneralInformationWidget.php index 9819d46522184b803d911484c002ffc3f417f1fd..9c53520680f81fd042d07465d6e96c5246f653ed 100644 --- a/typo3/sysext/dashboard/Classes/Widgets/T3GeneralInformationWidget.php +++ b/typo3/sysext/dashboard/Classes/Widgets/T3GeneralInformationWidget.php @@ -19,8 +19,6 @@ namespace TYPO3\CMS\Dashboard\Widgets; use TYPO3\CMS\Core\Information\Typo3Information; use TYPO3\CMS\Core\Information\Typo3Version; -use TYPO3\CMS\Dashboard\Widgets\Interfaces\WidgetConfigurationInterface; -use TYPO3\CMS\Dashboard\Widgets\Interfaces\WidgetInterface; use TYPO3\CMS\Fluid\View\StandaloneView; /** diff --git a/typo3/sysext/dashboard/Classes/Widgets/WidgetConfiguration.php b/typo3/sysext/dashboard/Classes/Widgets/WidgetConfiguration.php index 806f405d5acdd3987a04f510d36cfafc610fa591..c042917c5349c13d4fbd3cec007090db498bf583 100644 --- a/typo3/sysext/dashboard/Classes/Widgets/WidgetConfiguration.php +++ b/typo3/sysext/dashboard/Classes/Widgets/WidgetConfiguration.php @@ -17,8 +17,6 @@ declare(strict_types=1); namespace TYPO3\CMS\Dashboard\Widgets; -use TYPO3\CMS\Dashboard\Widgets\Interfaces\WidgetConfigurationInterface; - class WidgetConfiguration implements WidgetConfigurationInterface { /** diff --git a/typo3/sysext/dashboard/Classes/Widgets/Interfaces/WidgetConfigurationInterface.php b/typo3/sysext/dashboard/Classes/Widgets/WidgetConfigurationInterface.php similarity index 97% rename from typo3/sysext/dashboard/Classes/Widgets/Interfaces/WidgetConfigurationInterface.php rename to typo3/sysext/dashboard/Classes/Widgets/WidgetConfigurationInterface.php index d0098965fa7b04262926124e674247f3e6b33f27..71f3c6439cd233ade3bcbe09a9c6fe62a70eca1e 100644 --- a/typo3/sysext/dashboard/Classes/Widgets/Interfaces/WidgetConfigurationInterface.php +++ b/typo3/sysext/dashboard/Classes/Widgets/WidgetConfigurationInterface.php @@ -15,7 +15,7 @@ declare(strict_types=1); * The TYPO3 project - inspiring people to share! */ -namespace TYPO3\CMS\Dashboard\Widgets\Interfaces; +namespace TYPO3\CMS\Dashboard\Widgets; /** * Defines API of configuration for a widget. diff --git a/typo3/sysext/dashboard/Classes/Widgets/Interfaces/WidgetInterface.php b/typo3/sysext/dashboard/Classes/Widgets/WidgetInterface.php similarity index 95% rename from typo3/sysext/dashboard/Classes/Widgets/Interfaces/WidgetInterface.php rename to typo3/sysext/dashboard/Classes/Widgets/WidgetInterface.php index 6c16c87114a254cc669e2b8d448bb08c4a1c78ae..bd856818219c38610736872dc3af09d57fc5d683 100644 --- a/typo3/sysext/dashboard/Classes/Widgets/Interfaces/WidgetInterface.php +++ b/typo3/sysext/dashboard/Classes/Widgets/WidgetInterface.php @@ -15,7 +15,7 @@ declare(strict_types=1); * The TYPO3 project - inspiring people to share! */ -namespace TYPO3\CMS\Dashboard\Widgets\Interfaces; +namespace TYPO3\CMS\Dashboard\Widgets; /** * The WidgetInterface is the base interface for all kind of widgets. diff --git a/typo3/sysext/dashboard/Resources/Private/Templates/Widget/ChartWidget.html b/typo3/sysext/dashboard/Resources/Private/Templates/Widget/ChartWidget.html index 45b2fbe4d322b6d1aee742a4fc5cbb3b3844a101..e446cdfe702ab08e4119c0a5cd6d31dd55d757ba 100644 --- a/typo3/sysext/dashboard/Resources/Private/Templates/Widget/ChartWidget.html +++ b/typo3/sysext/dashboard/Resources/Private/Templates/Widget/ChartWidget.html @@ -10,7 +10,7 @@ <f:section name="footer"> <f:if condition="{button}"> - <a href="{button.link}" target="{button.target}" class="widget-cta">{f:translate(id: button.text, default: button.text)}</a> + <a href="{button.link}" target="{button.target}" class="widget-cta">{f:translate(id: button.title, default: button.title)}</a> </f:if> </f:section> diff --git a/typo3/sysext/dashboard/Resources/Private/Templates/Widget/CtaWidget.html b/typo3/sysext/dashboard/Resources/Private/Templates/Widget/CtaWidget.html index 97f590fa0c05b09e9845182eaacbe67d352bd6cc..226397f55559146d0c1b08e8ac597f8a18015d05 100644 --- a/typo3/sysext/dashboard/Resources/Private/Templates/Widget/CtaWidget.html +++ b/typo3/sysext/dashboard/Resources/Private/Templates/Widget/CtaWidget.html @@ -9,7 +9,7 @@ </f:section> <f:section name="footer"> <f:if condition="{button}"> - <a href="{button.link}" target="{button.target}" class="widget-cta">{f:translate(id: button.text, default: button.text)}</a> + <a href="{button.link}" target="{button.target}" class="widget-cta">{f:translate(id: button.title, default: button.title)}</a> </f:if> </f:section> </html> diff --git a/typo3/sysext/dashboard/Resources/Private/Templates/Widget/ListWidget.html b/typo3/sysext/dashboard/Resources/Private/Templates/Widget/ListWidget.html index de8f8c12cf45245013ffe5e605997ba74867d56d..d0d4cdf9fc8194773194ea15e8a7203971e33e5b 100644 --- a/typo3/sysext/dashboard/Resources/Private/Templates/Widget/ListWidget.html +++ b/typo3/sysext/dashboard/Resources/Private/Templates/Widget/ListWidget.html @@ -13,7 +13,7 @@ </f:section> <f:section name="footer"> <f:if condition="{button}"> - <a href="{button.link}" target="{button.target}" class="widget-cta">{f:translate(id: button.text, default: button.text)}</a> + <a href="{button.link}" target="{button.target}" class="widget-cta">{f:translate(id: button.title, default: button.title)}</a> </f:if> </f:section> </html> diff --git a/typo3/sysext/dashboard/Resources/Private/Templates/Widget/RssWidget.html b/typo3/sysext/dashboard/Resources/Private/Templates/Widget/RssWidget.html index 2a261352455e4fcee21ae9212d78508b6ec887ff..0e3e5459660723e3a9e0357908f3264e9fd91f0b 100644 --- a/typo3/sysext/dashboard/Resources/Private/Templates/Widget/RssWidget.html +++ b/typo3/sysext/dashboard/Resources/Private/Templates/Widget/RssWidget.html @@ -19,7 +19,7 @@ </f:section> <f:section name="footer"> <f:if condition="{button}"> - <a href="{button.link}" target="{button.target}" class="widget-cta">{f:translate(id: button.text, default: button.text)}</a> + <a href="{button.link}" target="{button.target}" class="widget-cta">{f:translate(id: button.title, default: button.title)}</a> </f:if> </f:section> </html> diff --git a/typo3/sysext/dashboard/Tests/Unit/WidgetRegistryTest.php b/typo3/sysext/dashboard/Tests/Unit/WidgetRegistryTest.php index a5989177162e3502797ffc660a1ed60d4851f9ae..72b093e24508d5709de2b57475ce47b465d0c83f 100644 --- a/typo3/sysext/dashboard/Tests/Unit/WidgetRegistryTest.php +++ b/typo3/sysext/dashboard/Tests/Unit/WidgetRegistryTest.php @@ -22,7 +22,7 @@ use Prophecy\Prophecy\ObjectProphecy; use Psr\Container\ContainerInterface; use TYPO3\CMS\Core\Authentication\BackendUserAuthentication; use TYPO3\CMS\Dashboard\WidgetRegistry; -use TYPO3\CMS\Dashboard\Widgets\Interfaces\WidgetConfigurationInterface; +use TYPO3\CMS\Dashboard\Widgets\WidgetConfigurationInterface; use TYPO3\TestingFramework\Core\Unit\UnitTestCase; class WidgetRegistryTest extends UnitTestCase diff --git a/typo3/sysext/install/Configuration/ExtensionScanner/Php/ClassNameMatcher.php b/typo3/sysext/install/Configuration/ExtensionScanner/Php/ClassNameMatcher.php index 247c46ad977a84b313037cdc90785eb9c59f9d57..fa2f8454a30a639d370800a0df58ac970ef19403 100644 --- a/typo3/sysext/install/Configuration/ExtensionScanner/Php/ClassNameMatcher.php +++ b/typo3/sysext/install/Configuration/ExtensionScanner/Php/ClassNameMatcher.php @@ -1478,4 +1478,59 @@ return [ 'Breaking-90660-RegistrationOfWidgetsChanged.rst', ], ], + 'TYPO3\CMS\Dashboard\Widgets\Interfaces\AdditionalCssInterface' => [ + 'restFiles' => [ + 'Breaking-91066-MovedInterfacesOfDashboard.rst', + ], + ], + 'TYPO3\CMS\Dashboard\Widgets\Interfaces\AdditionalJavascriptInterface' => [ + 'restFiles' => [ + 'Breaking-91066-MovedInterfacesOfDashboard.rst', + ], + ], + 'TYPO3\CMS\Dashboard\Widgets\Interfaces\ButtonProviderInterface' => [ + 'restFiles' => [ + 'Breaking-91066-MovedInterfacesOfDashboard.rst', + ], + ], + 'TYPO3\CMS\Dashboard\Widgets\Interfaces\ChartDataProviderInterface' => [ + 'restFiles' => [ + 'Breaking-91066-MovedInterfacesOfDashboard.rst', + ], + ], + 'TYPO3\CMS\Dashboard\Widgets\Interfaces\EventDataProviderInterface' => [ + 'restFiles' => [ + 'Breaking-91066-MovedInterfacesOfDashboard.rst', + ], + ], + 'TYPO3\CMS\Dashboard\Widgets\Interfaces\ListDataProviderInterface' => [ + 'restFiles' => [ + 'Breaking-91066-MovedInterfacesOfDashboard.rst', + ], + ], + 'TYPO3\CMS\Dashboard\Widgets\Interfaces\NumberWithIconDataProviderInterface' => [ + 'restFiles' => [ + 'Breaking-91066-MovedInterfacesOfDashboard.rst', + ], + ], + 'TYPO3\CMS\Dashboard\Widgets\Interfaces\RequireJsModuleInterface' => [ + 'restFiles' => [ + 'Breaking-91066-MovedInterfacesOfDashboard.rst', + ], + ], + 'TYPO3\CMS\Dashboard\Widgets\Interfaces\WidgetConfigurationInterface' => [ + 'restFiles' => [ + 'Breaking-91066-MovedInterfacesOfDashboard.rst', + ], + ], + 'TYPO3\CMS\Dashboard\Widgets\Interfaces\WidgetInterface' => [ + 'restFiles' => [ + 'Breaking-91066-MovedInterfacesOfDashboard.rst', + ], + ], + 'TYPO3\CMS\Dashboard\Utility\ButtonUtility' => [ + 'restFiles' => [ + 'Breaking-91066-RemovedButtonUtility.rst', + ], + ], ];