summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAndrewMurrell <amurrel@purdue.edu>2014-04-28 16:51:59 -0400
committerAndrewMurrell <amurrel@purdue.edu>2014-04-28 16:51:59 -0400
commit10ddfede25fbe6cf448e30323e1ffee98ed6e23a (patch)
tree05a678c923bff8eef391029fb8611f54fe401072
parenta528cedd36c77487496147b5880205799dbcb242 (diff)
Titleizer is me.
-rw-r--r--app/views/tournaments/_form.html.erb22
1 files changed, 11 insertions, 11 deletions
diff --git a/app/views/tournaments/_form.html.erb b/app/views/tournaments/_form.html.erb
index 19389b8..f53927d 100644
--- a/app/views/tournaments/_form.html.erb
+++ b/app/views/tournaments/_form.html.erb
@@ -1,9 +1,9 @@
<%= render "common/error_messages", :target => @tournament %>
<fieldset>
- <legend>Game type</legend>
+ <legend>Game Type</legend>
<%= form_for(@tournament, url: new_tournament_path, method: "get") do |f| %>
<p>
- <%= f.label :game_id, "Select a game type" %>
+ <%= f.label :game_id, "Select a Game Type" %>
<%= f.select(:game_id, Game.all.map{|game| [game.name, game.id]}) %>
<%= f.submit("Select") %>
</p>
@@ -29,12 +29,12 @@
<th>Maximum</th>
</tr>
<tr>
- <th>Players per team: </th>
+ <th>Players per Team: </th>
<td><%= f.text_field(:min_players_per_team, type: :number, min: 1) %></td>
<td><%= f.text_field(:max_players_per_team, type: :number, min: 1) %></td>
</tr>
<tr>
- <th>Teams per match: </th>
+ <th>Teams per Match: </th>
<td><%= f.text_field(:min_teams_per_match, type: :number, min: 1) %></td>
<td><%= f.text_field(:max_teams_per_match, type: :number, min: 1) %></td>
</tr>
@@ -42,7 +42,7 @@
</table>
<p>
- <%= f.label :scoring_method %>
+ <%= f.label :scoring_method, :scoring_method.to_s.titleize %>
<%= f.select(:scoring_method, @tournament.scoring_methods.map{|method| [method.humanize.titleize, method]}) %>
</p>
</fieldset>
@@ -52,7 +52,7 @@
<%= f.fields_for :settings do |setting_fields| %>
<% @tournament.tournament_settings.each do |setting| %>
<p>
- <%= setting_fields.label setting.name %>
+ <%= setting_fields.label setting.name, setting.name.to_s.titleize %>
<br>
<% case setting.vartype %>
<% when 0 %>
@@ -72,8 +72,8 @@
<% end %>
</ul>
<% when 4 %>
- <%= setting_fields.radio_button( setting.name, "true" ) %> True
- <%= setting_fields.radio_button( setting.name, "false" ) %> False
+ <%= setting_fields.radio_button( setting.name, "true" ) %> <b>True</b>
+ <%= setting_fields.radio_button( setting.name, "false" ) %> <b>False</b>
<% when 5 %>
<%= setting_fields.select( setting.name, setting.type_opt.split(',').collect {|opt| opt.humanize.titleize} ) %>
<% end %>
@@ -85,16 +85,16 @@
<%= f.fields_for :stages do |stages_fields| %>
<fieldset>
<legend>Stages</legend>
- <label for="num_stages">Number of tournament stages</label>
+ <label for="num_stages">Number of Tournament Stages</label>
<input type="number" name="num_stages" min="1" value="<%= params[:num_stages].to_i %>">
<%# stage_fields.submit("Set Stages") %>
<% for i in 1..(params[:num_stages].to_i) do %>
<%= stages_fields.fields_for i.to_s do |stage_fields| %>
<fieldset>
<legend>Stage <%= i %></legend>
- <%= stage_fields.label :scheduling_method %>
+ <%= stage_fields.label :scheduling_method, :scheduling_method.to_s.titleize %>
<%= stage_fields.select(:scheduling_method, @tournament.scheduling_methods.map{|method| [method.humanize.titleize, method]}) %>
- <%= stage_fields.label :seeding_method %>
+ <%= stage_fields.label :seeding_method, :seeding_method.to_s.titleize %>
<%= stage_fields.select(:seeding_method, @tournament.seeding_methods.map{|method| [method.humanize.titleize, method]}) %>
</fieldset>
<% end %>