You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
We have a bunch of required fields and use the rails-i18n gem to get localizations of "has to be filled out", "must be larger/smaller than...", etc. And that works great.
But copycopter seems to be bleeding the from one locale to another. I'm digging into the problem, and it seems to come from the client and it seems to matter which language you get the error message in first.
I think it goes something like:
Submit a form for a model with an error in German
View that same model in an index or show page in English
en:
activerecord:
errors:
models:
book:
attributes:
title:
blank: muss ausgefüllt werden
All the translations for that model show up, but it is getting the German error message
The text was updated successfully, but these errors were encountered:
Ah. That's exactly the behavior specified for DefaultCreator.
That seems like an odd design. Why populate with incorrect data? It makes it harder to see what needs to be localized, and it seems like it'd be trivial to fall back to another locale instead of adding this data.
What is the recommended solution for my problem:
I want to localize most text myself
I want to use all the default rails error localization messages, etc, for the rest. ie. I wanna be DRY.
We have a bunch of required fields and use the rails-i18n gem to get localizations of "has to be filled out", "must be larger/smaller than...", etc. And that works great.
But copycopter seems to be bleeding the from one locale to another. I'm digging into the problem, and it seems to come from the client and it seems to matter which language you get the error message in first.
I think it goes something like:
All the translations for that model show up, but it is getting the German error message
The text was updated successfully, but these errors were encountered: