summaryrefslogtreecommitdiff
path: root/app/views
diff options
context:
space:
mode:
authorguntasgrewal <guntasgrewal@gmail.com>2014-04-24 17:58:22 -0400
committerguntasgrewal <guntasgrewal@gmail.com>2014-04-24 17:58:22 -0400
commit76ee2a59964be6707cab25053697a2d848bbcd52 (patch)
treed9e815057b04cfb3af2b0c98ca3c2d1c808c4f3b /app/views
parent7fe1894becda038c3e85ba179dc27ce3b54690dc (diff)
parent976325f60e7706e480f3d45848897200734c8485 (diff)
Merge branch 'master' of https://github.com/LukeShu/leaguer
Diffstat (limited to 'app/views')
-rw-r--r--app/views/matches/index.html.erb7
1 files changed, 3 insertions, 4 deletions
diff --git a/app/views/matches/index.html.erb b/app/views/matches/index.html.erb
index 8a50fee..784d7db 100644
--- a/app/views/matches/index.html.erb
+++ b/app/views/matches/index.html.erb
@@ -12,8 +12,7 @@
</tr>
</thead>
<tbody>
- <% @tournament.stages_ordered.keys.sort.each do |stage_key| %>
- <% stage = @tournament.stages_ordered[stage_key] %>
+ <% @tournament.stages.order(:id).each do |stage| %>
<% stage.matches_ordered.keys.sort.reverse.each do |match_key| %><tr>
<% match = stage.matches_ordered[match_key] %>
<td><%= "Match #{match.id}" %></td>
@@ -36,6 +35,6 @@
<br>
-<% @tournament.stages_ordered.keys.sort.each do |stage_key| %>
- <div class="graph"><%= raw @tournament.stages_ordered[stage_key].to_svg(current_user) %></div>
+<% @tournament.stages.order(:id).each do |stage| %>
+ <div class="graph"><%= raw stage.to_svg(current_user) %></div>
<% end %>