Skip to content

Commit 04ea50c

Browse files
author
Markus Timtner
committed
added TYPO3 v13 compatibility
1 parent cbf2bb0 commit 04ea50c

File tree

4 files changed

+13
-5
lines changed

4 files changed

+13
-5
lines changed

Classes/ViewHelpers/GetpagecategoriesViewHelper.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -38,15 +38,15 @@ public static function renderStatic(
3838
'sys_category',
3939
'sys_category_record_mm',
4040
'mm',
41-
$queryBuilder->expr()->andX(
41+
$queryBuilder->expr()->and(
4242
$queryBuilder->expr()->eq('mm.uid_local', $queryBuilder->quoteIdentifier('sys_category.uid')),
4343
$queryBuilder->expr()->in('mm.uid_foreign', $pageUid ),
4444
$queryBuilder->expr()->eq('mm.tablenames', $queryBuilder->quote('pages')),
4545
$queryBuilder->expr()->eq('mm.fieldname', $queryBuilder->quote('categories'))
4646
)
4747
);
4848

49-
$pageCats = $query->execute()->fetchAll();
49+
$pageCats = $query->executeQuery()->fetchAllAssociative();
5050

5151
$result = '';
5252

composer.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@
1212
"GPL-2.0-or-later"
1313
],
1414
"require": {
15-
"typo3/cms-backend": "^10 || ^11 ||^12"
15+
"typo3/cms-backend": "^10 || ^11 ||^12 ||^13"
1616
},
1717
"autoload": {
1818
"psr-4": {

ext_emconf.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,14 +4,14 @@
44
'title' => 'MT BACKEND',
55
'description' => 'This TYPO3 Extension provides a preview of page properties in the page module, and a some css touchup.',
66
'category' => 'be',
7-
'version' => '12.0.2',
7+
'version' => '13.0.0',
88
'state' => 'stable',
99
'author' => 'Markus Timtner',
1010
'author_email' => '[email protected]',
1111
'author_company' => '',
1212
'constraints' => [
1313
'depends' => [
14-
'typo3' => '10.0.0-12.5.99',
14+
'typo3' => '10.0.0-13.9.99',
1515
],
1616
'conflicts' => [],
1717
'suggests' => [],

ext_localconf.php

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,15 @@
11
<?php
22
defined('TYPO3') || die('Access denied.');
33

4+
5+
$versionInformation = \TYPO3\CMS\Core\Utility\GeneralUtility::makeInstance(\TYPO3\CMS\Core\Information\Typo3Version::class);
6+
if ($versionInformation->getMajorVersion() > 12) {
7+
48
// Hook into the page module
59
$GLOBALS['TYPO3_CONF_VARS']['SC_OPTIONS']['cms/layout/db_layout.php']['drawHeaderHook']['mt_backend'] =
610
\MarkusTimtner\MtBackend\Hooks\PageHook::class . '->render';
11+
} else {
12+
13+
$GLOBALS['TYPO3_CONF_VARS']['BE']['stylesheets']['mt_backend'] = 'EXT:mt_backend/Resources/Public/Css/MyBeTouchup.css';
714

15+
}

0 commit comments

Comments
 (0)