Issue Bug Closed

#98105DatabaseBrowser does not respect TsConfig option pageTree.altElementBrowserMountPoints anymore

Christian Sonntag 08/09/22, 13:57 updated 07/09/24, 12:46

Description

Via TsConfig it’s supposed to be possible to set alternate mount points for BE-Users or BE-Groups. See https://docs.typo3.org/m/typo3/reference-tsconfig/main/en-us/UserTsconfig/Options.html#pagetree-altelementbrowsermountpoints

Until Typo3 11.x this also had an effect on the
\TYPO3\CMS\Recordlist\Browser\Databrowser
. On Apr 16th 2021 this functionality has been removed completeley. See https://sourcegraph.com/github.com/TYPO3-CMS/recordlist/-/commit/32258eacb313c403a69bc206b325ef9302d46578 Before the following method call had been fired right at the beginning of
DatabaseBrowser::render()
$this->setTemporaryDbMounts()
Part of that method was the call of
$backendUser->initializeWebmountsForElementBrowser()
Instead the call of
$this->getBackendUser()->initializeWebmountsForElementBrowser()
was added to
\TYPO3\CMS\Recordlist\LinkHandler\PageLinkHandler
and
\TYPO3\CMS\Recordlist\LinkHandler\RecordLinkHandler

The impact is that the TsConfig option to set alternate mount points does not apply to group fields anymore. I.e. until Typo3 10 it was possible to give BE-users the rights to select DB records of sys_folders that weren’t in their regular mount points.

Possible solution would be to re-add the call of
$this->getBackendUser()->initializeWebmountsForElementBrowser()
at the beginning of
DatabaseBrowser::render()
. See attached patch file

Reviews 2