Skip to content

Commit d1c1869

Browse files
committed
[BUGFIX] Fix severals bugs for TYPO3 v13
1 parent 3f95a12 commit d1c1869

2 files changed

Lines changed: 5 additions & 5 deletions

File tree

Classes/Service/RedirectDemandService.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -80,11 +80,11 @@ public function getRedirects(int $page = 1): array
8080
return $event->getRedirects();
8181
}
8282

83-
public function preparePagination(Demand $demand = null): array
83+
public function preparePagination(Demand $demand): array
8484
{
8585
$pagination = [];
8686
if ($demand !== null) {
87-
$count = $this->redirectRepository->countRedirectsByDemand($demand);
87+
$count = $this->redirectRepository->countRedirectsByByDemand($demand);
8888
$numberOfPages = ceil($count / $demand->getLimit());
8989
$endRecord = $demand->getOffset() + $demand->getLimit();
9090
if ($endRecord > $count) {

Resources/Private/Templates/Backend/List.html

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@
1818

1919
<tbody>
2020
<f:for each="{redirects}" key="domainName" as="redirect">
21-
<f:variable name="pageId" value="{rd:targetPageId(target:redirect.target)}" />
21+
<f:variable name="page" value="{rd:targetPageRecord(target:redirect.target)}" />
2222
<f:variable name="targetUri" value="{f:uri.typolink(parameter:redirect.target)}" />
2323
<tr
2424
class="{f:if(condition: '{redirect.integrity_status} !== {defaultIntegrityStatus}', then: 'danger')}"
@@ -48,8 +48,8 @@
4848

4949
<td>
5050
<f:link.typolink parameter="{redirect.target}" target="_blank" title="{f:translate(key: 'LLL:EXT:redirects/Resources/Private/Language/locallang_module_redirect.xlf:visit_destination')} {targetUri}">{targetUri}</f:link.typolink>
51-
(<f:if condition="{pageId}"><f:translate key="LLL:EXT:redirects/Resources/Private/Language/locallang_module_redirect.xlf:pageID"/>: {pageId},
52-
</f:if><f:translate key="LLL:EXT:redirects/Resources/Private/Language/locallang_module_redirect.xlf:destination_status_code"/>: {redirect.target_statuscode})
51+
(<f:if condition="{page}"><f:then><f:translate key="LLL:EXT:redirects/Resources/Private/Language/locallang_module_redirect.xlf:pageID"/>: {page.uid},</f:then></f:if>
52+
<f:translate key="LLL:EXT:redirects/Resources/Private/Language/locallang_module_redirect.xlf:destination_status_code"/>: {redirect.target_statuscode})
5353
</td>
5454

5555
<td>

0 commit comments

Comments
 (0)