rails部分错误 - 找不到路由

时间:2011-05-08 08:13:13

标签: ruby-on-rails routing partial-views

当我在没有AJAX的情况下呈现这个部分时它工作正常但是当我使用AJAX调用渲染它时,我得到以下异常。

我做错了什么?

ActionView::Template::Error (No route matches {:action=>"destroy", :followerid=>1,     :follower_type=>"topic", :controller=>"follows", :discussion_id=>91}):
2: <% discussion.followers.each do |topic| %>
3:     <% if topic.is_a? Topic%>
4:           <h3><%= render :partial => '/shared/topic_item', :locals => { :topic => topic }%></h3>
5:           <%= button_to("unTag", discussion_follow_path(discussion.id, :follower_type => "topic", :followerid => topic.id ), :method => :delete, :remote =>true) %>
6:     <%end%>
7: <%end%>

app / views / discussion / _edit_topics.html.erb:5:in _app_views_discussions__edit_topics_html_erb__847854145_2171200660_7386124' app/views/discussions/_edit_topics.html.erb:2:in each'   app / views / discussion / _edit_topics.html.erb:2:in _app_views_discussions__edit_topics_html_erb__847854145_2171200660_7386124' app/views/follows/create.js.erb:9:in _ app_views_follows_create_js_erb__1164388053_2171521760_0'

0 个答案:

没有答案