ActiveRecord translations disabled #147

Closed
morgoth opened this Issue Dec 3, 2009 · 5 comments

Projects

None yet

4 participants

@morgoth
Contributor
morgoth commented Dec 3, 2009

I have my translations in scope: "activerecord.attributes.model.attribute"
Now formtastic doesn't take them at all.
It makes @@label_str_method on key (humanize by default).
Do I really need to rewrite all my translations to scope: "formtastic.labels.model.attribute"
I don't think is a good idea.

Above changes were made by this commit:
http://github.com/justinfrench/formtastic/commit/863e3ffc6bdd19499379b7f1adfe67740b60df2b

@aaronchi
aaronchi commented Dec 3, 2009

I noticed this as well. I believe the class will respond to human_attribute_name even if the translation is not defined explicitly. In that case, it just returns a humanized version of the attribute. You may need to do something more clever like compare the human_attribute_value to a humanized string and use the label_str_method only if they match.

@lardawge
Contributor
lardawge commented Dec 3, 2009

Justin, Now we know what broke... I will have a look...

@justinfrench
Owner

Ok, looks like José reverted your patch on master. I'm going to revert the doc patch that went with it. Clearly we need some specs that describe the current behaviour well, then we can figure out a patch that works for everyone.

I'm going to go make an un-broken gem ;)

@justinfrench
Owner

Changed tags to 1.x too, happy for it to be done sooner, but it's not a blocker.

@justinfrench
Owner

Ah, this should be closed as I've pushed a new gem, will find the previous issue and re-open.

This issue was closed.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment