search for: employee_contact

Displaying 1 result from an estimated 1 matches for "employee_contact".

2006 Jan 10
0
Validation and Single-Table Inheritance
...e if anyone else has seen this. I have the following: class Contact < ActiveRecord validates_presence_of :first_name ... end class EmployeeContact < Contact ... end If I do the following while running the server or in test mode, no error occurs eventhough the first name is invalid: @employee_contact.update_attributes({:first_name => ""''}) When I do the same in script/console, #update_attributes returns false (an error occurs as expected). If I add: validates_presence_of :first_name to the EmployeeContact model, the validation does fail as expected. Anyone have any idea...