mirror of
https://github.com/jcwimer/wrestlingApp
synced 2026-03-25 01:14:43 +00:00
57 lines
1.3 KiB
Plaintext
57 lines
1.3 KiB
Plaintext
|
|
<%= form_for(@wrestler) do |f| %>
|
|
<% if @wrestler.errors.any? %>
|
|
<div id="error_explanation">
|
|
<h2><%= pluralize(@wrestler.errors.count, "error") %> prohibited this wrestler from being saved:</h2>
|
|
|
|
<ul>
|
|
<% @wrestler.errors.full_messages.each do |msg| %>
|
|
<li><%= msg %></li>
|
|
<% end %>
|
|
</ul>
|
|
</div>
|
|
<% end %>
|
|
|
|
<div class="field">
|
|
<%= f.label :name %><br>
|
|
<%= f.text_field :name %>
|
|
</div>
|
|
|
|
<% if @school %>
|
|
<%= f.hidden_field :school_id, :value => @school.id %>
|
|
<% else %>
|
|
<div class="field">
|
|
<%= f.label 'School' %><br>
|
|
<%= f.collection_select :school_id, @tournament.schools, :id, :name %>
|
|
</div>
|
|
<% end %>
|
|
<div class="field">
|
|
<%= f.label 'Weight Class' %><br>
|
|
<%= f.collection_select :weight_id, @weights, :id, :max %>
|
|
|
|
</div>
|
|
<div class="field">
|
|
<%= f.label "Season Wins" %><br>
|
|
<%= f.number_field :season_win %>
|
|
</div>
|
|
<div class="field">
|
|
<%= f.label "Season Losses" %><br>
|
|
<%= f.number_field :season_loss %>
|
|
</div>
|
|
|
|
<div class="field">
|
|
<%= f.label "Seed Criteria" %><br>
|
|
<%= f.text_field :criteria %>
|
|
</div>
|
|
<div class="field">
|
|
<%= f.label "Check box if extra" %> <%= f.check_box :extra %>
|
|
</div>
|
|
</br>
|
|
</br>
|
|
<div class="actions">
|
|
<%= f.submit :class=>"btn btn-success"%>
|
|
</div>
|
|
<% end %>
|
|
|
|
|