forked from elovation/elovation
-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
project wide ruby 1.8 to ruby 1.9 hash syntax
- Loading branch information
Showing
23 changed files
with
72 additions
and
72 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,50 +1,50 @@ | ||
<%= form_for @game, :html => {class: "form-horizontal"} do |f| %> | ||
<%= form_for @game, html: {class: "form-horizontal"} do |f| %> | ||
<%= f.error_messages %> | ||
<%= f.hidden_field :min_number_of_players_per_team, value: 1, :class => "input-mini" %> | ||
<%= f.hidden_field :min_number_of_teams, value: 2, :class => "input-mini" %> | ||
<%= f.hidden_field :min_number_of_players_per_team, value: 1, class: "input-mini" %> | ||
<%= f.hidden_field :min_number_of_teams, value: 2, class: "input-mini" %> | ||
|
||
<h1>New Game</h1> | ||
|
||
<div class="control-group"> | ||
<%= f.label :name, :class => "control-label" %> | ||
<%= f.label :name, class: "control-label" %> | ||
<div class="controls"> | ||
<%= f.text_field :name, :class => "input-xlarge" %> | ||
<%= f.text_field :name, class: "input-xlarge" %> | ||
</div> | ||
</div> | ||
|
||
<div class="control-group"> | ||
<%= f.label :rating_type, :class => "control-label" %> | ||
<%= f.label :rating_type, class: "control-label" %> | ||
<div class="controls"> | ||
<%= f.select :rating_type, Game::RATER_MAPPINGS.map{|k, v| [v.description, k]}, {}, :class => "input-xlarge" %> | ||
<%= f.select :rating_type, Game::RATER_MAPPINGS.map{|k, v| [v.description, k]}, {}, class: "input-xlarge" %> | ||
</div> | ||
</div> | ||
|
||
<div class="control-group"> | ||
<%= f.label :max_number_of_players_per_team, 'Maximum number of players per team', :class => "control-label" %> | ||
<%= f.label :max_number_of_players_per_team, 'Maximum number of players per team', class: "control-label" %> | ||
<div class="controls"> | ||
<%= f.number_field :max_number_of_players_per_team, :class => "input-mini" %> | ||
<%= f.number_field :max_number_of_players_per_team, class: "input-mini" %> | ||
<span class="help-inline">Leave blank for no restriction</span> | ||
</div> | ||
</div> | ||
|
||
<div class="control-group"> | ||
<%= f.label :max_number_of_teams, 'Maximum number of teams', :class => "control-label" %> | ||
<%= f.label :max_number_of_teams, 'Maximum number of teams', class: "control-label" %> | ||
<div class="controls"> | ||
<%= f.number_field :max_number_of_teams, :class => "input-mini" %> | ||
<%= f.number_field :max_number_of_teams, class: "input-mini" %> | ||
<span class="help-inline">Leave blank for no restriction</span> | ||
</div> | ||
</div> | ||
|
||
<div class="control-group"> | ||
<div class="controls"> | ||
<%= f.check_box :allow_ties, :class => "input-mini" %> | ||
<%= f.label :allow_ties, :class => "control-label" %> | ||
<%= f.check_box :allow_ties, class: "input-mini" %> | ||
<%= f.label :allow_ties, class: "control-label" %> | ||
</div> | ||
</div> | ||
|
||
<div class="form-actions"> | ||
<%= f.submit :class => "btn btn-primary" %> | ||
<%= link_to "Cancel", root_path, :class => "btn btn-warning" %> | ||
<%= f.submit class: "btn btn-primary" %> | ||
<%= link_to "Cancel", root_path, class: "btn btn-warning" %> | ||
</div> | ||
|
||
<% end %> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,28 +1,28 @@ | ||
<h1> | ||
<%= image_tag(gravatar_url(@player, :size => 80)) %> | ||
<%= image_tag(gravatar_url(@player, size: 80)) %> | ||
<%= @player.name %> | ||
</h1> | ||
|
||
<section class="action-buttons"> | ||
<span><%= link_to 'Edit Player', edit_player_path(@player), :class => "btn btn-primary" %></span> | ||
<span><%= link_to 'Edit Player', edit_player_path(@player), class: "btn btn-primary" %></span> | ||
<% if @player.results.empty? %> | ||
<span><%= link_to "Delete", player_path(@player), :method => :delete, :confirm => "Are you sure?", :class => "btn btn-danger" %></span> | ||
<span><%= link_to "Delete", player_path(@player), method: :delete, confirm: "Are you sure?", class: "btn btn-danger" %></span> | ||
<% end %> | ||
</section> | ||
|
||
<div class="row-fluid"> | ||
<div class="span8"> | ||
<h2>Recent Results</h2> | ||
<% if @player.recent_results.any? %> | ||
<%= render :partial => 'shared/results', :object => @player.recent_results, locals: {show_game: true} %> | ||
<%= render partial: 'shared/results', object: @player.recent_results, locals: {show_game: true} %> | ||
<% else %> | ||
<span>No results, play some games!</span> | ||
<% end %> | ||
</div> | ||
<div class="span4"> | ||
<h2>Ratings</h2> | ||
<ol> | ||
<%= render :partial => 'rating', :collection => @player.ratings %> | ||
<%= render partial: 'rating', collection: @player.ratings %> | ||
</ol> | ||
</div> | ||
</div> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,3 @@ | ||
<ol id='results'> | ||
<%= render :partial => 'shared/result', :collection => results, locals: {show_game: show_game} %> | ||
<%= render partial: 'shared/result', collection: results, locals: {show_game: show_game} %> | ||
</ol> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.