Displaying 2 results from an estimated 2 matches for "address_format".
Did you mean:
address_form
2005 Dec 16
4
Validation with Aggregation
...s
end
...
end
How can I best take advantage of Rails'' validation, given that I''d
like to only specify the validation rules for EmailAddress once. The
validation rules might look something like:
validates_presence_of :name, :address
validates_format_of :email, :with => ADDRESS_FORMAT
I''m guessing the obvious answer is to create an email_addresses table
and use belongs_to but that seems (to me at least) a somewhat heave-
handed approach.
Regards,
Simon
--
Simon Harris
RedHill Consulting, Pty. Ltd.
12/55-67 Batman Street
West Melbourne VIC Australia 3003
http://ww...
2005 Dec 17
1
How to use validation with aggregation (composed_of)?
...s
end
...
end
How can I best take advantage of Rails'' validation, given that I''d
like to only specify the validation rules for EmailAddress once. The
validation rules might look something like:
validates_presence_of :name, :address
validates_format_of :email, :with => ADDRESS_FORMAT
I''m guessing the obvious answer is to create an email_addresses table
and use belongs_to but that seems (to me at least) a somewhat heave-
handed approach.
Regards,
Simon
--
Simon Harris
RedHill Consulting, Pty. Ltd.
12/55-67 Batman Street
West Melbourne VIC Australia 3003
http://ww...