1
0
mirror of https://github.com/jcwimer/wrestlingApp synced 2026-04-07 14:57:48 +00:00

Update seeds on one page.

This commit is contained in:
2015-03-16 15:06:45 -04:00
parent 8d6fab3428
commit d6a9abffac
3 changed files with 12 additions and 2 deletions

View File

@@ -23,6 +23,7 @@
</tr>
</thead>
<tbody>
<%= form_tag @wrestlers_update_path do %>
<% @wrestlers.order("original_seed asc").each do |wrestler| %>
<% if wrestler.weight_id == @weight.id %>
<tr>
@@ -30,7 +31,9 @@
<td><%= School.find(wrestler.school_id).name %></td>
<td>
<% if user_signed_in? %>
<%= wrestler.original_seed %>
<%= fields_for "wrestler[]", wrestler do |w| %>
<%= w.text_field :original_seed %>
<% end %>
<% else %>
<%= wrestler.original_seed %>
<% end %>
@@ -50,6 +53,9 @@
<% end %>
</tbody>
</table>
<%= submit_tag "Save"%>
<% end %>