diff options
author | guntasgrewal <guntasgrewal@gmail.com> | 2014-03-25 17:30:10 -0400 |
---|---|---|
committer | guntasgrewal <guntasgrewal@gmail.com> | 2014-03-25 17:30:10 -0400 |
commit | 0c22c4bd9a0b4a0b0ff5840c1af41c0b320e3529 (patch) | |
tree | 2fc2082814e513ec5d68b22e7fa07d268df6d788 /app/views/matches/index.html.erb | |
parent | 8435c0a5ec9889a9da6ede2e24c044d64b279095 (diff) |
added match status
Diffstat (limited to 'app/views/matches/index.html.erb')
-rw-r--r-- | app/views/matches/index.html.erb | 14 |
1 files changed, 8 insertions, 6 deletions
diff --git a/app/views/matches/index.html.erb b/app/views/matches/index.html.erb index 60df1b5..400efb4 100644 --- a/app/views/matches/index.html.erb +++ b/app/views/matches/index.html.erb @@ -3,6 +3,7 @@ <table> <thead> <tr> + <th>Status</th> <th>Tournament</th> <th>Name</th> <th>Winner</th> @@ -13,14 +14,15 @@ </thead> <tbody> - <% @tournament.matches.each do |match| %> + <% @matches.each do |match| %> <tr> - <td><%= match.tournament.id %></td> + <td><%= match.status %></td> + <td><%= match.tournament %></td> <td><%= match.name %></td> <td><%= match.winner %></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> + <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> </tr> <% end %> </tbody> @@ -28,4 +30,4 @@ <br> -<%= link_to 'New Match', new_tournament_match_path %> +<%= link_to 'New Match', new_match_path %> |