Updated: Comment 0
Problem/Motivation
When you translate config entities appearing in the route slug they have the wrong language (default aka. en), so they aren't translated.
Proposed resolution
The problem is that the routing system comes before the current language context is resetted, chaning the priority a bit fixes that.
So first the locale config subscriber steps in and resets the current language once the request is available, then the routing system executes its logic and loads the config entity.
Remaining tasks
User interface changes
API changes
Related Issues
Comment | File | Size | Author |
---|---|---|---|
#5 | config-entity-upcast-default-context-2094797-3.patch | 3.38 KB | webflo |
#2 | contact-entity-label-translation-test.patch | 1.66 KB | Gábor Hojtsy |
#1 | config-2094797-1.patch | 950 bytes | dawehner |
Comments
Comment #1
dawehnerThis fixes the problem described in config_translation.
Comment #2
Gábor HojtsyHere is an untested test only. :D
Comment #3
tstoecklerCan't we simply make contact.module a requirement of the test?
I think "work" is not very precise. I would suggest "the entity loaded from the request upcasting has active locale overrides."
Typo
Marking needs work for 3. at least.
Comment #4
webflo CreditAttribution: webflo commentedJust put both patches together. Looks good. Fixed two issues in the test from comment 3.
This page callbacks needs the permission "access site-wide contact form".
Typo in $categry_label
Comment #5
webflo CreditAttribution: webflo commentedUps.
Comment #6
Gábor HojtsyLooks good to me. Let's get this in! Marking blocker for #1952394: Add configuration translation user interface module in core since this fails the perfect tests there :) The fails appeared now because contact was just recently converted to the routing system and upcast in the routing vs. the old menu hook based method.
Comment #7
tstoecklerLooks good, thanks. The bot can prove me wrong, if it wants, but for humans this is RTBC.
Comment #8
tstoecklerx-post.
Comment #9
webchickCommitted and pushed to 8.x. Thanks!
Comment #10
Gábor HojtsyWoot, yay!