lib/chinook_database/models/customer.rb in chinook_database-0.1.4 vs lib/chinook_database/models/customer.rb in chinook_database-0.1.5

- old
+ new

@@ -1,21 +1,4 @@ class Customer < ActiveRecord::Base - self.table_name = 'Customer' - self.primary_key = 'CustomerId' - - alias_attribute :id, 'CustomerId' - alias_attribute :first_name, 'FirstName' - alias_attribute :last_name, 'LastName' - alias_attribute :company, 'Company' - alias_attribute :address, 'Address' - alias_attribute :city, 'City' - alias_attribute :state, 'State' - alias_attribute :country, 'Country' - alias_attribute :postal_code, 'PostalCode' - alias_attribute :phone, 'Phone' - alias_attribute :fax, 'Fax' - alias_attribute :email, 'Email' - alias_attribute :support_rep_id, 'SupportRepId' - - belongs_to :support_rep, class_name: 'Employee', foreign_key: 'SupportRepId' - has_many :invoices, foreign_key: 'CustomerId' + belongs_to :support_rep, class_name: 'Employee', foreign_key: 'support_rep_id' + has_many :invoices end \ No newline at end of file