Skip to content
Snippets Groups Projects
Commit af00dcc3 authored by Georg Ringer's avatar Georg Ringer Committed by Wouter Wolters
Browse files

[TASK] Deprecate more methods of DocumentTemplate

Unused and to be deprecated methods:

- wrapInCData
- funcMenu
- getDragDropCode
- getTabMenu
- getVersionSelector

Change-Id: I8fb5cf470a5bd2c21b43f9cc28030047188aab32
Resolves: #72733
Releases: master
Reviewed-on: https://review.typo3.org/45939


Reviewed-by: default avatarOliver Klee <typo3-coding@oliverklee.de>
Reviewed-by: default avatarMarkus Klein <markus.klein@typo3.org>
Tested-by: default avatarMarkus Klein <markus.klein@typo3.org>
Reviewed-by: default avatarWouter Wolters <typo3@wouterwolters.nl>
Tested-by: default avatarWouter Wolters <typo3@wouterwolters.nl>
parent 9aa1e2c6
Branches
Tags
No related merge requests found
......@@ -1051,9 +1051,11 @@ function jumpToUrl(URL) {
*
* @param string $string Input string
* @return string Output string
* @deprecated since TYPO3 CMS 8, will be removed in TYPO3 CMS 9.
*/
public function wrapInCData($string)
{
GeneralUtility::logDeprecatedFunction();
$string = '/*<![CDATA[*/' . $string . '/*]]>*/';
return $string;
}
......@@ -1094,9 +1096,11 @@ function jumpToUrl(URL) {
* @param string $content Content cell content (left)
* @param string $menu Menu cell content (right)
* @return string HTML output
* @deprecated since TYPO3 CMS 8, will be removed in TYPO3 CMS 9.
*/
public function funcMenu($content, $menu)
{
GeneralUtility::logDeprecatedFunction();
return '
<table border="0" cellpadding="0" cellspacing="0" width="100%" id="typo3-funcmenu">
<tr>
......@@ -1136,9 +1140,11 @@ function jumpToUrl(URL) {
* @param string $table indicator of which table the drag and drop function should work on (pages or folders)
* @param string $additionalJavaScriptCode adds more code to the additional javascript code
* @return void
* @deprecated since TYPO3 CMS 8, will be removed in TYPO3 CMS 9.
*/
public function getDragDropCode($table, $additionalJavaScriptCode = '')
{
GeneralUtility::logDeprecatedFunction();
$this->pageRenderer->loadRequireJsModule('TYPO3/CMS/Backend/LegacyTree', 'function() {
DragDrop.table = "' . $table . '";
' . $additionalJavaScriptCode . '
......@@ -1158,9 +1164,11 @@ function jumpToUrl(URL) {
* @param string $script is the script to send the &id to, if empty it's automatically found
* @param string $addparams is additional parameters to pass to the script.
* @return string HTML code for tab menu
* @deprecated since TYPO3 CMS 8, will be removed in TYPO3 CMS 9.
*/
public function getTabMenu($mainParams, $elementName, $currentValue, $menuItems, $script = '', $addparams = '')
{
GeneralUtility::logDeprecatedFunction();
$content = '';
if (is_array($menuItems)) {
if (!is_array($mainParams)) {
......@@ -1218,9 +1226,11 @@ function jumpToUrl(URL) {
* @param int $id Page id to create selector for.
* @param bool $noAction If set, there will be no button for swapping page.
* @return string
* @deprecated since TYPO3 CMS 8, will be removed in TYPO3 CMS 9.
*/
public function getVersionSelector($id, $noAction = false)
{
GeneralUtility::logDeprecatedFunction();
if (
ExtensionManagementUtility::isLoaded('version') &&
!ExtensionManagementUtility::isLoaded('workspaces')
......
================================================================
Deprecation: #72733 - Deprecate more methods of DocumentTemplate
================================================================
Description
===========
The following methods from ``TYPO3\CMS\Backend\Template\DocumentTemplate`` have been deprecated:
* ``wrapInCData``
* ``funcMenu``
* ``getDragDropCode``
* ``getTabMenu``
* ``getVersionSelector``
Impact
======
Calling one of the aforementioned methods will write an entry in the deprecation log.
Affected Installations
======================
Instances with custom backend modules that use one of the aforementioned methods.
Migration
=========
Some replacements are available in the ``\TYPO3\CMS\Backend\Template\ModuleTemplate`` class.
\ No newline at end of file
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment