class FaqCategory < ApplicationRecord
translates :description, touch: true
globalize_accessors :locales => I18n.available_locales, :attributes => translated_attribute_names
end
controller -> globalize_accessors
Strong parameters aren't working either.
Example with strong parameters:
params.require(:product).permit(*Product.globalize_attribute_names)
If you need to permit non-translatable attributes as well, you could include them with:
Looks like this gem wont be supported anymore. So, if anybody tries to use this on rails 6, here it goes:
My gem set:
model -> globalize_accessors
Apparently, the defaults ain't working, you should define yourself!
controller -> globalize_accessors Strong parameters aren't working either.
You can "workaround" with:
In my case, I'm building a simple FAQ API for our application, so this won't be an issue.