mirror of
https://github.com/jcwimer/wrestlingApp
synced 2026-04-05 06:07:20 +00:00
All brackets page gives 1 bracket per page
This commit is contained in:
@@ -21,31 +21,32 @@
|
|||||||
<div id="exportable">
|
<div id="exportable">
|
||||||
<% @tournament.weights.sort_by{|w| w.max}.each do |w| %>
|
<% @tournament.weights.sort_by{|w| w.max}.each do |w| %>
|
||||||
<table class='pagebreak'>
|
<table class='pagebreak'>
|
||||||
<td>
|
<h5><strong><%= @tournament.name %> - <%= w.max %> lbs Bracket</strong></h5>
|
||||||
<% @weight = w %>
|
<tr>
|
||||||
<% @matches = @tournament.matches.select{|m| m.weight_id == @weight.id} %>
|
<td valign="top" style="padding: 10px;">
|
||||||
<% @wrestlers = Wrestler.where(weight_id: @weight.id) %>
|
<% @weight = w %>
|
||||||
<% @pools = w.poolRounds(@matches) %>
|
<% @matches = @tournament.matches.select{|m| m.weight_id == @weight.id} %>
|
||||||
<h5><%= @weight.max %> lbs Bracket</h5>
|
<% @wrestlers = Wrestler.where(weight_id: @weight.id) %>
|
||||||
|
<% @pools = w.poolRounds(@matches) %>
|
||||||
<%= render 'pool' %>
|
<%= render 'pool' %>
|
||||||
</td>
|
</td>
|
||||||
</table>
|
|
||||||
<table class='pagebreak'>
|
|
||||||
<td>
|
<td valign="top" style="padding: 10px;">
|
||||||
<% if w.pool_bracket_type == "twoPoolsToFinal" %>
|
<% if w.pool_bracket_type == "twoPoolsToFinal" %>
|
||||||
<%= render 'twoPoolFinalBracket' %>
|
<%= render 'twoPoolFinalBracket' %>
|
||||||
<% end %>
|
<% end %>
|
||||||
<% if w.pool_bracket_type == "twoPoolsToSemi" %>
|
<% if w.pool_bracket_type == "twoPoolsToSemi" %>
|
||||||
<%= render 'twoPoolSemiBracket' %>
|
<%= render 'twoPoolSemiBracket' %>
|
||||||
<% end %>
|
<% end %>
|
||||||
<% if w.pool_bracket_type == "fourPoolsToQuarter" %>
|
<% if w.pool_bracket_type == "fourPoolsToQuarter" %>
|
||||||
<%= render 'fourPoolQuarterBracket' %>
|
<%= render 'fourPoolQuarterBracket' %>
|
||||||
<% end %>
|
<% end %>
|
||||||
<% if w.pool_bracket_type == "fourPoolsToSemi" %>
|
<% if w.pool_bracket_type == "fourPoolsToSemi" %>
|
||||||
<%= render 'fourPoolSemiBracket' %>
|
<%= render 'fourPoolSemiBracket' %>
|
||||||
<% end %>
|
<% end %>
|
||||||
</td>
|
</td>
|
||||||
|
</tr>
|
||||||
</table>
|
</table>
|
||||||
<% end %>
|
<% end %>
|
||||||
</div>
|
</div>
|
||||||
|
|||||||
Reference in New Issue
Block a user