Hi Ibon,

You should see all routes when running "rake routes". There you should
find the one you are looking for.

If it's not there, you might be missing something in
notes_controller.rb, like:

auto_actions_for :user, :create

Warm regards,
Ignacio

El 10-12-2015 a las 13:59, Ibon Castilla escribió:
> Hi there,
> 
> I'm trying to figure out how is the default URL route for a
> new_for_model controller action. Let me explain it better:
> 
> * I have User and Note models. A User has a lot of Notes and a Note
> belongs to a User, so 1:N relation between them :)
> * I want to set a link in the User's show view that routes to
> new_for_user in Note's controller: a "new note" DRYML view for that user.
> 
> Which will be the route in this case?. I have tried (I already know that
> mostly of them are completely stupid, but I should try them):
> 
> * /users/4559/notes/new_for_user         => "No route matches ..."
> * /users/4559/notes                             => "No route matches ..."
> * /users/new_for_user/                         => "Couldn't find User
> with id=new_for_user"
> * /users/new_for_user/4559                  => "No route matches ..."
> * /users/4559/new_for_user/                 => "No route matches ..."
> 
> I have also check for some documentation at hobocentral.net and in the
> archive messages of this group, but sadly couldn't find any relevant
> information about it :/
> 
> Any hint about this topic please? :)
> 
> Many thanks in advance, Ibon.
> 
> -- 
> You received this message because you are subscribed to the Google
> Groups "Hobo Users" group.
> To unsubscribe from this group and stop receiving emails from it, send
> an email to [email protected]
> <mailto:[email protected]>.
> To post to this group, send email to [email protected]
> <mailto:[email protected]>.
> Visit this group at http://groups.google.com/group/hobousers.
> For more options, visit https://groups.google.com/d/optout.

-- 
You received this message because you are subscribed to the Google Groups "Hobo 
Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
Visit this group at http://groups.google.com/group/hobousers.
For more options, visit https://groups.google.com/d/optout.

Reply via email to