news icon indicating copy to clipboard operation
news copied to clipboard

Categories selection on news records not showing in v10

Open haassie opened this issue 4 years ago • 4 comments

Bug Report

Current Behavior If you edit a news item in TYPO3 v10, you will get a notification with an error 500. If you checkout the XHR request, you get the error: "Argument 1 passed to TYPO3\CMS\Core\Tree\TableConfiguration\DatabaseTreeDataProvider::__construct() must implement interface Psr\EventDispatcher\EventDispatcherInterface, array given, called in /var/www/html/public/typo3/sysext/core/Classes/Utility/GeneralUtility.php on line 3469".

As a result, the category field is not rendered properly.

Expected behavior/output I want to be able to choose categories ;-)

Environment

  • TYPO3 version(s): [10.3.0-dev]
  • news version: [e.g. 8.0.0-dev]
  • Is your TYPO3 installation set up with Composer (Composer Mode): yes
  • OS: ddev

Possible Solution In https://review.typo3.org/c/Packages/TYPO3.CMS/+/62331 the usage of the DatabaseTreeDataProvider is been deprecated. The __construct method is changed resulting in an error now. Best is to migrate to PSR-14 events.

Additional context Problem is that those events are only for v10 and I guess you also want to support previous LTS version(s).

haassie avatar Feb 05 '20 13:02 haassie

See https://forge.typo3.org/issues/90302

haassie avatar Feb 05 '20 14:02 haassie

@haassie disabled the dataprovider for the moment, issue is open as this is of course no final solution

georgringer avatar Feb 15 '20 08:02 georgringer

Also related to #1107

dogawaf avatar Jun 23 '20 12:06 dogawaf

@georgringer I just found out that the DatabaseTreeDataProvider was commented in the current version of news because of this issue. However, when I uncomment it in TYPO3 11, everything seems to be working as expected. I will reactivate it through a TCA override in my installation, so I can live with it, but maybe you could verify my findings and thinking about enabling it, too?

lorenzulrich avatar Nov 21 '22 20:11 lorenzulrich