[#4177] Added Contract associations.

This commit is contained in:
Eric Davis
2010-06-17 12:13:14 -07:00
parent 9d08bc9ef9
commit 1138616e77
2 changed files with 7 additions and 0 deletions
+5
View File
@@ -1,3 +1,8 @@
class Contract < ActiveRecord::Base
unloadable
# Associations
belongs_to :project
belongs_to :account_executive, :class_name => 'User', :foreign_key => 'account_executive_id'
end
+2
View File
@@ -1,4 +1,6 @@
require File.dirname(__FILE__) + '/../test_helper'
class ContractTest < ActiveSupport::TestCase
should_belong_to :account_executive
should_belong_to :project
end