Bug #86588
closedRouteEnhancer on rootPage raise a PageNotFoundException exception
0%
Description
I added a routeEnhancer with a PersistedAliasMapper aspect for a plugin.
routeEnhancers:
Foowebsite:
type: Extbase
limitToPages: [6]
extension: Foowebsite
plugin: Pi1
routes:
- routePath: '/{country_slug}'
_controller: 'Country::show'
_arguments: {'country_slug': 'country'}
defaultController: 'Country::list'
aspects:
country_slug:
type: PersistedAliasMapper
tableName: 'tx_foowebsite_domain_model_country'
routeFieldName: 'slug'
If i use this route on the root Website(is_siteroot=1) i get a PageNotFoundExeption, on a sub page all works fine.
- example.com/aegypten -> PageNotFoundException
- example.com/default-title/aegypten -> works fine
Updated by Sebastian Fischer about 6 years ago
I also don't get cHash output in urls neither on rootpage nor subpage.
routeEnhancers:
PageTypeSuffix:
type: PageType
default: '.html'
map:
'.html': 0
NewsPlugin:
type: Extbase
limitToPages: [1,4]
extension: News
plugin: Pi1
routes:
- routePath: '/seite/{page}'
_controller: 'News::list'
_arguments: {'page': '@widget_0/currentPage'}
- routePath: '/nachricht/{news_title}'
_controller: 'News::detail'
_arguments: {'news_title': 'news'}
defaultController: 'News::list'
defaults:
page: '0'
aspects:
news_title:
type: PersistedAliasMapper
tableName: 'tx_news_domain_model_news'
routeFieldName: 'path_segment'
Removed all my previous comment because it's now working. What helped was the comment from Susi to remove all language related config from typoscript. With the above site config it's working fine for me.
Updated by Joerg Kummer about 6 years ago
In the note2 it works, cause I guess the routing goes from rootpage (uid1) to a subpage (uid4).
In issue description Torsten mentioned that "on a sub page all works fine".
When you want to stay on rootpage, and want configure all views for example list- and detail-view for rootpage only, then you got the PageNotFoundExeption as described in this issue. I can confirm this behavior in 9.5.0LTS
Updated by Susanne Moog about 6 years ago
- Sprint Focus set to On Location Sprint
Updated by Susanne Moog almost 5 years ago
- Sprint Focus deleted (
On Location Sprint)
Updated by Benni Mack over 4 years ago
- Status changed from New to Needs Feedback
Can you please recheck with TYPO3 v9.5.18?
Updated by Riccardo De Contardi about 4 years ago
- Status changed from Needs Feedback to Closed
I guess it is safe to close this issue for now; if you think that this is the wrong decision or experience the issue again, please reopen it or ping me and I'll do. Thank you.