No longer depend on hstore_translate to allow usage of jsonb_translate
RailsAdminHstoreTranslate adds tabbed interface to rails_admin for multilingual models (using hstore_translate gem)
Heavily based on RailsAdminGlobalizeField and rails_admin_mongoid_localize_field
It adds custom field type that you can use for hstore translations association.
Only PostgreSQL is supported.
Then add this gem and run bundle
gem 'rails_admin_hstore_translate'
Don't forget to set I18n.available_locale config, because it uses that to determine what tabs to show
Add configuration to your model. :locale
field is always required.
config.model 'Post' do
field :name do
tabbed false
end
field :description do
tabbed false
end
end
- Fork it
- Create your feature branch (
git checkout -b my-new-feature
) - Commit your changes (
git commit -am 'Add some feature'
) - Push to the branch (
git push origin my-new-feature
) - Create new Pull Request