diff options
author | Jon Leighton <j@jonathanleighton.com> | 2011-03-16 18:54:34 +0000 |
---|---|---|
committer | Jon Leighton <j@jonathanleighton.com> | 2011-03-16 18:54:34 +0000 |
commit | 9abc94c44516afdcfe4a3b202c336c9578fd6d0d (patch) | |
tree | c6af8dd568ec7bbd522c91c16b704e184e250968 /activerecord/test/models/author.rb | |
parent | 37d93ea16046add35fecd8c279e868869ee744a5 (diff) | |
download | rails-9abc94c44516afdcfe4a3b202c336c9578fd6d0d.tar.gz rails-9abc94c44516afdcfe4a3b202c336c9578fd6d0d.tar.bz2 rails-9abc94c44516afdcfe4a3b202c336c9578fd6d0d.zip |
oracle, y u defy me
Diffstat (limited to 'activerecord/test/models/author.rb')
-rw-r--r-- | activerecord/test/models/author.rb | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/activerecord/test/models/author.rb b/activerecord/test/models/author.rb index f362f70dec..e0cbc44265 100644 --- a/activerecord/test/models/author.rb +++ b/activerecord/test/models/author.rb @@ -131,10 +131,12 @@ class Author < ActiveRecord::Base has_many :post_categories, :through => :posts, :source => :categories has_many :category_post_comments, :through => :categories, :source => :post_comments - has_many :misc_posts, :class_name => 'Post', :conditions => "posts.title LIKE 'misc post%'" + has_many :misc_posts, :class_name => 'Post', + :conditions => { :posts => { :title => ['misc post by bob', 'misc post by mary'] } } has_many :misc_post_first_blue_tags, :through => :misc_posts, :source => :first_blue_tags - has_many :misc_post_first_blue_tags_2, :through => :posts, :source => :first_blue_tags_2, :conditions => "posts.title LIKE 'misc post%'" + has_many :misc_post_first_blue_tags_2, :through => :posts, :source => :first_blue_tags_2, + :conditions => { :posts => { :title => ['misc post by bob', 'misc post by mary'] } } scope :relation_include_posts, includes(:posts) scope :relation_include_tags, includes(:tags) |