Translate nested model errors

4 views
Skip to first unread message

Serafino Picozzi

unread,
Oct 7, 2013, 12:50:15 PM10/7/13
to rubyonra...@googlegroups.com
Hi!

In rails 4, how do you translate model and attributes names for models
with accepts_nested_attributes_for? Everything works fine except for the
error messages of the nested model.

Here's what I have so far (without my attempt to translate the nested
model:

activerecord:
errors:
<<: *errors
models:
player: Giocatore
score: Punteggio
attributes:
player:
some_field: Blah...
score:
points: Punti

When a player is created, I have a nested form that allows the creation
of an initial score, therefore the Player model has:
accepts_nested_attributes_for :scores

--
Posted via http://www.ruby-forum.com/.
Reply all
Reply to author
Forward
0 new messages