<h4>Championship Bracket</h4>
<div class="bracket">
  <!--Round 1-->
  <%  @round_matches = @matches.select{|m|m.bracket_position == "Bracket Round of 16"} %>
  <%= render 'bracket_round' %>
  <!--Round 2-->
  <% @round_matches = @matches.select{|m|m.bracket_position == "Quarter"} %>
  <%= render 'bracket_round' %>
  <!--Round 3-->
  <% @round_matches = @matches.select{|m|m.bracket_position == "Semis"} %>
  <%= render 'bracket_round' %>
  <!--Round 4-->
  <% @final_match = @matches.select{|m|m.bracket_position == "1/2"} %>
  <% @winner_place = "1st" %>
  <%= render 'bracket_final' %>
</div>
<h4>3/4 place match</h4>
<div class="bracket">
  <!--Round 1-->
  <% @final_match = @matches.select{|m|m.bracket_position == "3/4"} %>
  <% @winner_place = "3rd" %>
  <%= render 'bracket_final' %>
</div>
<h4>Consolation Bracket</h4>
<div class="bracket">
  <!--Round 1-->
  <% @round_matches = @matches.select{|m|m.bracket_position == "Conso Round of 8"} %>		
  <%= render 'bracket_round' %>
  <!--Round 2-->
  <% @round_matches = @matches.select{|m|m.bracket_position == "Conso Quarter"} %>	
  <%= render 'bracket_round' %>
  <!--Round 3-->
  <% @round_matches = @matches.select{|m|m.bracket_position == "Conso Semis"} %>	
  <%= render 'bracket_round' %>
  <!--Round 4-->
  <% @final_match = @matches.select{|m|m.bracket_position == "5/6"} %>
  <% @winner_place = "5th" %>
  <%= render 'bracket_final' %>
</div>
<% if @tournament.number_of_placers >= 8 %>
  <h4>7/8 place match</h4>
  <div class="bracket">
    <!--Round 1-->
    <% @final_match = @matches.select{|m|m.bracket_position == "7/8"} %>
    <% @winner_place = "7th" %>
    <%= render 'bracket_final' %>
  </div>
<% end %>