summaryrefslogtreecommitdiff
path: root/app/views/matches/index.html.erb
diff options
context:
space:
mode:
Diffstat (limited to 'app/views/matches/index.html.erb')
-rw-r--r--app/views/matches/index.html.erb10
1 files changed, 5 insertions, 5 deletions
diff --git a/app/views/matches/index.html.erb b/app/views/matches/index.html.erb
index 71db08c..ff42ef1 100644
--- a/app/views/matches/index.html.erb
+++ b/app/views/matches/index.html.erb
@@ -13,14 +13,14 @@
</thead>
<tbody>
- <% @matches.each do |match| %>
+ <% @tournament.matches.each do |match| %>
<tr>
<td><%= match.tournament %></td>
<td><%= match.name %></td>
<td><%= match.winner %></td>
- <td><%= link_to 'Show', match %></td>
- <td><%= link_to 'Edit', edit_match_path(match) %></td>
- <td><%= link_to 'Destroy', match, method: :delete, data: { confirm: 'Are you sure?' } %></td>
+ <td><%= link_to 'Show', tournament_match_path(@tournament, match) %></td>
+ <td><%= link_to 'Edit', edit_tournament_match_path(@tournament, match) %></td>
+ <td><%= link_to 'Destroy', tournament_match_path(@tournament, match), method: :delete, data: { confirm: 'Are you sure?' } %></td>
</tr>
<% end %>
</tbody>
@@ -28,4 +28,4 @@
<br>
-<%= link_to 'New Match', new_match_path %>
+<%= link_to 'New Match', new_tournament_match_path %>