-
Notifications
You must be signed in to change notification settings - Fork 1
Open
Description
TYPOO3 CMS v10.4.17 here. - The composer based installation from TER with composer require colorcube/content-overview did work for me, but after opening the Web/Info/Content Overview Page I got a PHP error page:
Call to undefined method Doctrine\DBAL\Driver\Mysqli\Mysqli Statement::fetch Associative()
So in ext/content_overview/Classes/Controller/ContentOverviewController.php
I had to replace fetchAssociative() with fetchAll()
I'll post the whole method here . See last line.
/**
* Get an alternative language record for a specific page / language
*
* @param int $pageId Page ID to look up for.
* @param int $langId Language UID to select for.
* @return array pages_languages_overlay record
*/
public function getLangStatus($pageId, $langId)
{
$queryBuilder = GeneralUtility::makeInstance(ConnectionPool::class)->getQueryBuilderForTable('pages');
$queryBuilder->getRestrictions()->removeAll()->add(GeneralUtility::makeInstance(DeletedRestriction::class));
return $queryBuilder->select('*')
->from('pages')
->where(
$queryBuilder->expr()->eq(
'l10n_parent',
$queryBuilder->createNamedParameter($pageId, \PDO::PARAM_INT)
),
$queryBuilder->expr()->eq(
$GLOBALS['TCA']['pages']['ctrl']['languageField'],
$queryBuilder->createNamedParameter($langId, \PDO::PARAM_INT)
)
)
->execute()
->fetchAll();
//->fetchAssociative();
}
That is a one-line fix, and it seems to work just fine.
Metadata
Metadata
Assignees
Labels
No labels