Finne Jager wrote in post #971133:
>> Since your resources are nested, you need to use the array syntax of
>> form_for so that the proper route is generated.
>
> <%= form_for :command_officer, @command_officer do |f| %>

No!  You need the *parent* resource names in there, I think.  Rails 
already knows what kind of resource @command_officer itself is.
>
> That one doesn't generate any errors, thanks.
> But when I fill in the form and press submit, I get:
>
>
> Routing Error
> No route matches "/incidents/41/timesheet/command_officer/new"

Best,
-- 
Marnen Laibow-Koser
http://www.marnen.org
mar...@marnen.org

Sent from my iPhone

-- 
Posted via http://www.ruby-forum.com/.

-- 
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-t...@googlegroups.com.
To unsubscribe from this group, send email to 
rubyonrails-talk+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/rubyonrails-talk?hl=en.

Reply via email to