Hi, Ive recently bene trying to find a way to edit my tutorials (which
are stored inside categories) in my RoR app. To edit my category's
names I use the following in the category show file:

<%= link_to 'Edit', edit_category_path(@category) %>

And this is edit in the categories controller:

  def edit
    @category = Category.find(params[:id])
  end



but when I change this to tutorials:

<%= link_to 'Edit', edit_tutorial_path(@tutorial) %>

and

 def edit
    @tutorial = Tutorial.find(params[:id])
  end


I get this error on the tutorial show page:

undefined method `edit_tutorial_path' for #<ActionView::Base:
0x5ce52fc>

(or something of those origins)

I had the origional category system setup for me, so I dont know that
much about how the categories are editable. Therefore its hard for me
to figure out how to edit the tutorials.

Please Help,

(If you need any more information please just ask),

Thanks In Advance,


Joe


--~--~---------~--~----~------------~-------~--~----~
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@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