On 3 July 2012 14:59, Clint326
<clint.laskowski-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>
wrote:> I''m a relative n00b when it comes to Rails. I''ve gone
through Michael
> Hartl''s tutorials (both editions, books and screencasts) and I can
build a
> basic CRUD web app without help. However, for a personal project
I''m working
> on, I''m lost as to how to move forward. Here''s the
situation ...
>
> I have a model called Project with two fields, name:string and due:date.
> Project is associated (has_many) with a model called Task (with rows
> description:text, status:text, and project_id:integer) which is associated
> back to Project with belongs_to. All this works fine.
>
> What I''d really like to be able to do is click on a particular
project on
> the Project#index page and be taken to a page that lets me enter as many
> tasks as I need ... not just one at a time. I''m wondering how I
can do this?
> Do I need to use AJAX or one of the popular JS frameworks?
>
> Can anyone point me to an example of how to do this?
These railscast [1] and [2] show how to do what I think you want,
however they are a bit out of date now. I see there are revised
episodes but to get that you have to pay :(
Start by looking at those to get the basic idea.
Does anyone know of more up to date examples?
Colin
[1] http://railscasts.com/episodes/196-nested-model-form-part-1
[2] http://railscasts.com/episodes/197-nested-model-form-part-2
--
You received this message because you are subscribed to the Google Groups
"Ruby on Rails: Talk" group.
To post to this group, send email to
rubyonrails-talk-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org
To unsubscribe from this group, send email to
rubyonrails-talk+unsubscribe-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org
For more options, visit this group at
http://groups.google.com/group/rubyonrails-talk?hl=en-US.