diff options
author | Jeremy Kemper <jeremy@bitsweat.net> | 2006-05-06 23:37:56 +0000 |
---|---|---|
committer | Jeremy Kemper <jeremy@bitsweat.net> | 2006-05-06 23:37:56 +0000 |
commit | 50f538b72bbe6657627c9efe55b65d167956d1b7 (patch) | |
tree | a3fd7a90a3d205ffd05f20ed4127c426e73cbbc4 /activerecord/test/fixtures/author.rb | |
parent | e0123041750b724daa1e5fb4e7e66b233b2b1bed (diff) | |
download | rails-50f538b72bbe6657627c9efe55b65d167956d1b7.tar.gz rails-50f538b72bbe6657627c9efe55b65d167956d1b7.tar.bz2 rails-50f538b72bbe6657627c9efe55b65d167956d1b7.zip |
Allow :uniq => true with has_many :through associations.
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@4325 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
Diffstat (limited to 'activerecord/test/fixtures/author.rb')
-rw-r--r-- | activerecord/test/fixtures/author.rb | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/activerecord/test/fixtures/author.rb b/activerecord/test/fixtures/author.rb index 99142f6621..ec844f6238 100644 --- a/activerecord/test/fixtures/author.rb +++ b/activerecord/test/fixtures/author.rb @@ -26,6 +26,9 @@ class Author < ActiveRecord::Base has_many :categorizations has_many :categories, :through => :categorizations + has_many :categorized_posts, :through => :categorizations, :source => :post + has_many :unique_categorized_posts, :through => :categorizations, :source => :post, :uniq => true + has_many :nothings, :through => :kateggorisatons, :class_name => 'Category' has_many :author_favorites @@ -73,4 +76,4 @@ end class AuthorFavorite < ActiveRecord::Base belongs_to :author belongs_to :favorite_author, :class_name => "Author", :foreign_key => 'favorite_author_id' -end
\ No newline at end of file +end |