On Nov 14, 2:42 am, Leonardo Mateo wrote:
> On Sat, Nov 14, 2009 at 6:37 AM, MaggotChild wrote:
> > In Rails, providing the associated ID works fine with has_one but if
> > you try to do this with a has_many:
>
> > form_for(@country) do |form|
> > form.select :state_ids, @states
> > form.sel
On Sat, Nov 14, 2009 at 6:37 AM, MaggotChild wrote:
>
> When modifying a model that has a has_one or has_many relationship
> people usually create form that will submit the id of the selected
> associated object. Rails takes this into consideration with
> validations: validate_presence_of :coun
2 matches
Mail list logo