-
-
Notifications
You must be signed in to change notification settings - Fork 1.1k
Open
Description
Describe the bug
After switching to pretty URLs, I can't switch locale in CRUD controllers anymore.
To Reproduce
Package version: 4.24.4
PHP version: 8.4
Locale configuration in config/packages/translation.yaml
:
framework:
default_locale: ru
enabled_locales: ['en', 'ru']
Dashboard controller:
public function configureDashboard(): Dashboard
{
return Dashboard::new()
->setLocales(['en', 'ru'])
;
}
- I'm on the page http://localhost:7000/ru/admin/dashboard/customer (Ru locale)
- The locale switcher shows two languages - English and Russian
- The En locale link is: http://localhost:7000/ru/admin/dashboard/customer?_locale=en
- When I click on the English link, nothing changes, I still see the Russian language page.
- If I edit the URL manually to switch to the
/en/
URL prefix, I get theNo route found for "GET http://localhost:7000/en/admin/dashboard/customer"
error.
This issue doesn't happen on the Dashboard http://localhost:7000/ru/admin/dashboard - the link to the English version is correct: http://localhost:7000/en/admin/dashboard and on custom routes (non-CRUD controllers).
Metadata
Metadata
Assignees
Labels
No labels