aboutsummaryrefslogtreecommitdiffstats
path: root/activerecord/test/models/company.rb
diff options
context:
space:
mode:
authorrick <technoweenie@gmail.com>2008-09-20 13:00:20 -0700
committerrick <technoweenie@gmail.com>2008-09-20 13:00:20 -0700
commit22e830f883af0b56de81186c184751b6398d0141 (patch)
tree0de20fad9f3a7ce2e49d660d1243b5b02a32e290 /activerecord/test/models/company.rb
parent0aef9d1a2651fa0acd2adcd2de308eeb0ec8cdd2 (diff)
parenta3b7fa78bfdc33e45e39c095b67e02d50a2c7bea (diff)
downloadrails-22e830f883af0b56de81186c184751b6398d0141.tar.gz
rails-22e830f883af0b56de81186c184751b6398d0141.tar.bz2
rails-22e830f883af0b56de81186c184751b6398d0141.zip
Merge branch 'master' of git@github.com:rails/rails
Diffstat (limited to 'activerecord/test/models/company.rb')
-rw-r--r--activerecord/test/models/company.rb2
1 files changed, 2 insertions, 0 deletions
diff --git a/activerecord/test/models/company.rb b/activerecord/test/models/company.rb
index cd435948a1..0eb8ae0a15 100644
--- a/activerecord/test/models/company.rb
+++ b/activerecord/test/models/company.rb
@@ -55,6 +55,8 @@ class Firm < Company
has_many :readonly_clients, :class_name => 'Client', :readonly => true
has_many :clients_using_primary_key, :class_name => 'Client',
:primary_key => 'name', :foreign_key => 'firm_name'
+ has_many :clients_grouped_by_firm_id, :class_name => "Client", :group => "firm_id", :select => "firm_id"
+ has_many :clients_grouped_by_name, :class_name => "Client", :group => "name", :select => "name"
has_one :account, :foreign_key => "firm_id", :dependent => :destroy, :validate => true
has_one :unvalidated_account, :foreign_key => "firm_id", :class_name => 'Account', :validate => false