Archived
fixed bug with double :id in path
This commit is contained in:
@@ -1,12 +1,10 @@
|
|||||||
<%= link_to @forum.group, forumgroup_path(@forum.group) %> → <%= link_to @forum %>
|
<%= link_to @forum.group, forumgroup_path(@forum.group) %> → <%= link_to @forum %>
|
||||||
<h1><%= @forum.name %></h1>
|
<h1><%= @forum.name %></h1>
|
||||||
<%= link_to "New thread", new_forumthread_path, class: "btn blue" %>
|
<%= link_to "New thread", new_forum_forumthread_path(@forum), class: "btn blue" %>
|
||||||
<div id="forum_threads">
|
<div id="forum_threads">
|
||||||
<% @threads.each do |thread| %>
|
<% @threads.each do |thread| %>
|
||||||
<div class="group" id="thread-<%= thread.id %>">
|
<div class="forum_thread" id="thread-<%= thread.id %>">
|
||||||
<div class="header">
|
<%= link_to thread.title, forum_forumthread_path(@forum, thread) %>
|
||||||
<%= link_to thread.title, forumthread_path(thread) %>
|
|
||||||
</div>
|
|
||||||
</div>
|
</div>
|
||||||
<% end %>
|
<% end %>
|
||||||
</div>
|
</div>
|
||||||
+1
-3
@@ -24,12 +24,10 @@ Site::Application.routes.draw do
|
|||||||
end
|
end
|
||||||
|
|
||||||
resources :forums, path: 'forums' do
|
resources :forums, path: 'forums' do
|
||||||
|
resources :forumthreads, path: 'threads'
|
||||||
collection do
|
collection do
|
||||||
resources :forumgroups, path: 'groups'
|
resources :forumgroups, path: 'groups'
|
||||||
end
|
end
|
||||||
member do
|
|
||||||
resources :forumthreads, path: 'threads'
|
|
||||||
end
|
|
||||||
end
|
end
|
||||||
|
|
||||||
match '/status' => 'status#show'
|
match '/status' => 'status#show'
|
||||||
|
|||||||
Reference in New Issue
Block a user