1
0
mirror of https://github.com/jcwimer/wrestlingApp synced 2026-03-25 01:14:43 +00:00

Added info to match edit (mat -> show) and up_matches pages.

This commit is contained in:
2017-11-13 08:42:16 -05:00
parent 94bb5affa3
commit 5cfcfe0448
4 changed files with 21 additions and 21 deletions

BIN
.tmux.sh.swp Normal file

Binary file not shown.

Binary file not shown.

View File

@@ -10,15 +10,15 @@
</ul>
</div>
<% end %>
<h4>Bout <%= @match.bout_number %></h4>
<h4>Bout: <%= @match.bout_number %> </h4><h4>Round: <%= @match.round %></h4><h4>Weight: <%= @match.weight_max %> lbs</h4>
<table class="table">
<thead>
<tr>
<th><%= @w1.name %> <select id="w1-color" onchange="changeW1Color(this)">
<th><%= @w1.name %> - <%= @w1.school.name %> <select id="w1-color" onchange="changeW1Color(this)">
<option value="green">Green</option>
<option value="red">Red</option>
</select><br>Last Match: <%= if @w1.lastMatch != nil then time_ago_in_words(@w1.lastMatch.updated_at) end%></th>
<th><%= @w2.name %> <select id="w2-color" onchange="changeW2Color(this)">
<th><%= @w2.name %> - <%= @w2.school.name %> <select id="w2-color" onchange="changeW2Color(this)">
<option value="red">Red</option>
<option value="green">Green</option>
</select><br>Last Match: <%= if @w2.lastMatch != nil then time_ago_in_words(@w2.lastMatch.updated_at) end%></th>

View File

@@ -29,10 +29,10 @@
<% @mats.each.map do |m| %>
<tr>
<td><%= m.name %></td>
<td><% if m.unfinishedMatches.first %><%=m.unfinishedMatches.first.bout_number%><br><%= m.unfinishedMatches.first.w1_name %> vs. <%= m.unfinishedMatches.first.w2_name %><% end %></td>
<td><% if m.unfinishedMatches.second %><%=m.unfinishedMatches.second.bout_number%><br><%= m.unfinishedMatches.second.w1_name %> vs. <%= m.unfinishedMatches.second.w2_name %><% end %></td>
<td><% if m.unfinishedMatches.third %><%=m.unfinishedMatches.third.bout_number%><br><%= m.unfinishedMatches.third.w1_name %> vs. <%= m.unfinishedMatches.third.w2_name %><% end %></td>
<td><% if m.unfinishedMatches.fourth %><%=m.unfinishedMatches.fourth.bout_number%><br><%= m.unfinishedMatches.fourth.w1_name %> vs. <%= m.unfinishedMatches.fourth.w2_name %><% end %></td>
<td><% if m.unfinishedMatches.first %><strong><%=m.unfinishedMatches.first.bout_number%></strong> - <%= m.unfinishedMatches.first.weight_max %> lbs<br><%= m.unfinishedMatches.first.w1_name %> vs. <%= m.unfinishedMatches.first.w2_name %><% end %></td>
<td><% if m.unfinishedMatches.second %><strong><%=m.unfinishedMatches.second.bout_number%></strong> - <%= m.unfinishedMatches.second.weight_max %> lbs<br><%= m.unfinishedMatches.second.w1_name %> vs. <%= m.unfinishedMatches.second.w2_name %><% end %></td>
<td><% if m.unfinishedMatches.third %><strong><%=m.unfinishedMatches.third.bout_number%></strong> - <%= m.unfinishedMatches.third.weight_max %> lbs<br><%= m.unfinishedMatches.third.w1_name %> vs. <%= m.unfinishedMatches.third.w2_name %><% end %></td>
<td><% if m.unfinishedMatches.fourth %><strong><%=m.unfinishedMatches.fourth.bout_number%></strong> - <%= m.unfinishedMatches.fourth.weight_max %> lbs<br><%= m.unfinishedMatches.fourth.w1_name %> vs. <%= m.unfinishedMatches.fourth.w2_name %><% end %></td>
</tr>
<% end %>
</tbody>