Re: [Rails] join table naming

2013-04-26 Thread tamouse mailing lists
On Wed, Apr 24, 2013 at 2:47 PM, Colin Law wrote: > On 24 April 2013 19:00, Dave Castellano wrote: >> Hi, >> I’m an amateur learning rails and could use some help… >> I created a join table “pictures_questions” >> and append to it in the following way: >> @picture = Picture.new(params[:picture])

Re: [Rails] join table naming

2013-04-24 Thread Colin Law
On 24 April 2013 19:00, Dave Castellano wrote: > Hi, > I’m an amateur learning rails and could use some help… > I created a join table “pictures_questions” > and append to it in the following way: > @picture = Picture.new(params[:picture]) > … > if @picture.save > @question.pictures

[Rails] join table naming

2013-04-24 Thread Dave Castellano
Hi, I’m an amateur learning rails and could use some help… I created a join table “pictures_questions” and append to it in the following way: @picture = Picture.new(params[:picture]) … if @picture.save @question.pictures << @picture Everything works fine but honestly I think I got th