%=javascript_include_tag :defaults %>
Same color region champs play each other in final four:
<%= form_tag({:controller => 'teams', :action => 'change', :id => @pool.id}, {:method => "POST"}) %> <% @pool.region_seedings.each_with_index do |arr, index| -%> <% region_name = arr[0]; teams = arr[1] %>Seed | Name | Short Name |
---|---|---|
<%= seed_idx + 1%> | <%=content_tag("div", "", :id => "team_name_#{index}_#{seed_idx}_auto_complete", :class => "auto_complete") %> <%= auto_complete_field "team_name_#{index}_#{seed_idx}", :url => { :action => 'auto_complete_for_team_name'}, :after_update_element => 'function(element, value) {short_id = element.id.replace("team_name", "short_name"); $(short_id).value = value.readAttribute("short")}' %> | <%=content_tag("div", "", :id => "short_name_#{index}_#{seed_idx}_auto_complete", :class => "auto_complete") %> <%= auto_complete_field "short_name_#{index}_#{seed_idx}", :url => { :action => 'auto_complete_for_short_name'}, :after_update_element => 'function(element, value) {name_id = element.id.replace("short_name", "team_name"); $(name_id).value = value.readAttribute("name")}' %> |