Project

General

Profile

Actions

Bug #95072

closed

Custom aspect leads to list view on hidden elements

Added by Stephan Bauer over 2 years ago. Updated about 1 year ago.

Status:
Closed
Priority:
Should have
Assignee:
Category:
Link Handling, Site Handling & Routing
Target version:
-
Start date:
2021-09-01
Due date:
% Done:

0%

Estimated time:
TYPO3 Version:
10
PHP Version:
7.4
Tags:
Complexity:
Is Regression:
Sprint Focus:
On Location Sprint

Description

I made a custom aspect for EXT:news for categories.
Everything works as expected but there is a problem with hidden elements or wrong links.

Instead of the error page with the http status 404 the site shows the list view or a server error
(1/1) Symfony\Component\Routing\Exception\InvalidParameterException
Parameter "xxx" for route "tx_news_pi1_1" must match ".+" ("" given) to generate a corresponding URL.

I also made an mini extension to see if this is a EXT:news problem but the problem occurs there also.

I tried to separate list and show and tested 'limitToPages' with no luck.

The EXT is attached and this is my yaml config:

  Test:
    type: Extbase
    extension: Test
    plugin: Test
    routes:
      -
        routePath: '/{title}'
        _controller: 'Test::show'
        _arguments:
          title: test
      -
        routePath: /
        _controller: 'Test::list'
      -
        routePath: '/{categoryName}'
        _controller: 'Test::list'
        _arguments:
          categoryName: overwriteDemand/categories
    defaultController: 'Test::list'
    aspects:
      title:
        type: PersistedAliasMapper
        tableName: tx_test_domain_model_test
        routeFieldName: slug
      categoryName:
        type: CategoriesValueMapper

Files

test_1.0.0_202109012329.zip (20.2 KB) test_1.0.0_202109012329.zip Test extension Stephan Bauer, 2021-09-01 21:29
clipboard-202109151627-kkb3v.png (23.2 KB) clipboard-202109151627-kkb3v.png Stephan Bauer, 2021-09-15 14:27
clipboard-202109151627-zofzw.png (22.3 KB) clipboard-202109151627-zofzw.png Stephan Bauer, 2021-09-15 14:27

Related issues 1 (0 open1 closed)

Related to TYPO3 Core - Bug #94585: Siteconfig - 404 error not triggered if routeEnhancers is configuredClosed2021-07-19

Actions
Actions

Also available in: Atom PDF