staticfilecache icon indicating copy to clipboard operation
staticfilecache copied to clipboard

For Typo3 v11, the Backend Module uses deprecated ViewHelper

Open m41r opened this issue 4 years ago • 1 comments

Bug Report

Current Behavior

If you enabled the Deprecation log, log entries are triggered once you call the Backend Module, like

Wed, 26 Jan 2022 18:09:16 +0100 [NOTICE] request="3bfe5d1fdb640" component="TYPO3.CMS.deprecations": Core: Error handler (BE): TYPO3 Deprecation Notice: TYPO3\CMS\Fluid\ViewHelpers\Be\ContainerViewHelper will be removed in TYPO3 v12. in /var/www/html/httpdocs/typo3/sysext/fluid/Classes/ViewHelpers/Be/ContainerViewHelper.php line 84 

and

Wed, 26 Jan 2022 18:09:16 +0100 [NOTICE] request="3bfe5d1fdb640" component="TYPO3.CMS.deprecations": Core: Error handler (BE): TYPO3 Deprecation Notice: Method makeShortcutIcon() is deprecated and will be removed in v12. Please use ShortcutButton->setArguments() instead. in /var/www/html/httpdocs/typo3/sysext/backend/Classes/Template/ModuleTemplate.php line 587

Those entries are generated from

  • the <f:be.container/> ViewHelper (https://github.com/lochmueller/staticfilecache/blob/master/Resources/Private/Layouts/Backend.html#L1)
  • and the <f:be.buttons.shortcut/> ViewHelper (https://github.com/lochmueller/staticfilecache/blob/master/Resources/Private/Layouts/Backend.html#L25)

Both are deprecated and should be avoided for Typo3 v11.

  • https://docs.typo3.org/c/typo3/cms-core/main/en-us/Changelog/11.3/Deprecation-94225-FbecontainerViewHelper.html
  • https://docs.typo3.org/c/typo3/cms-core/main/en-us/Changelog/11.0/Deprecation-92132-DeprecatedViewHelperFbebuttonsshortcut.html

Expected behavior/output

No deprecation log entry :)

Environment

  • TYPO3 version(s): ^11.5.5
  • staticfilecache version: ^12.4.3
  • Is your TYPO3 installation set up with Composer (Composer Mode): yes

Possible Solution

Follow the Migration section in the mentioned links above... but to be honest, idk if this also works in Typo3 v10 simultaneously.

m41r avatar Jan 26 '22 17:01 m41r

Thanks @m41r I think this is the same as in this fix: https://github.com/lochmueller/calendarize/commit/5f91b739cdcc009c6eedebd0d94005b6d927fc65 I will check this shortly.

lochmueller avatar Jan 26 '22 17:01 lochmueller