diff options
author | David Heinemeier Hansson <david@loudthinking.com> | 2004-12-16 13:42:21 +0000 |
---|---|---|
committer | David Heinemeier Hansson <david@loudthinking.com> | 2004-12-16 13:42:21 +0000 |
commit | 87297f1c4be22c10de138709ba2d6c3ace4b0117 (patch) | |
tree | 7f2ec2e8aea4a907834bae84e9cfb51c8588fb67 /activerecord/test/fixtures | |
parent | 4d6bfc7a3615c68544ce10373e699eec1dfea669 (diff) | |
download | rails-87297f1c4be22c10de138709ba2d6c3ace4b0117.tar.gz rails-87297f1c4be22c10de138709ba2d6c3ace4b0117.tar.bz2 rails-87297f1c4be22c10de138709ba2d6c3ace4b0117.zip |
Added assumption that a Symbol-based scope should end in _id unless it does so already and that you can pass vanilla string-based scopes as a parameter
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@183 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
Diffstat (limited to 'activerecord/test/fixtures')
-rw-r--r-- | activerecord/test/fixtures/mixin.rb | 10 |
1 files changed, 9 insertions, 1 deletions
diff --git a/activerecord/test/fixtures/mixin.rb b/activerecord/test/fixtures/mixin.rb index 6da85e55e7..0c3bf5000a 100644 --- a/activerecord/test/fixtures/mixin.rb +++ b/activerecord/test/fixtures/mixin.rb @@ -9,5 +9,13 @@ class ListMixin < ActiveRecord::Base def self.table_name "mixins" end - +end + + +class ListWithStringScopeMixin < ActiveRecord::Base + acts_as_list :column => "pos", :scope => 'parent_id = #{parent_id}' + + def self.table_name + "mixins" + end end
\ No newline at end of file |