README.rdoc in simple_model_translations-0.1.1 vs README.rdoc in simple_model_translations-0.1.2
- old
+ new
@@ -14,9 +14,18 @@
class ArticleTranslation < ActiveRecord::Base
translation_for :article
end
+or, if you are not going to add some additional behavior to translation class (for example, validations),
+you can use translation class, created for you by default:
+
+ class Article < ActiveRecord::Base
+ translates :name, :content
+ end
+
+ArticleTranslation will be generated automagically :)
+
Also, you'll need a migration:
create_table(:article_translations) do |t|
t.references :article
t.string :locale