Remove disused & hidden match score page

This commit is contained in:
Prommah 2015-11-04 14:17:57 +00:00
parent aa633e4795
commit a27b72afac
2 changed files with 0 additions and 43 deletions

6
app/controllers/matches_controller.rb Normal file → Executable file
View file

@ -24,12 +24,6 @@ class MatchesController < ApplicationController
def extra
end
def score
raise AccessError unless @match.can_update? cuser, [:matchers_attributes]
@contester = @match.contester1.team.is_leader?(cuser) ? @match.contester1 : @match.contester2
@n = 0
end
def ref
raise AccessError unless @match.can_update? cuser, [:report]
@n = 0

View file

@ -1,37 +0,0 @@
<h2>
<%= namelink @match.contester1.team %> vs <%= namelink @match.contester2.team %>
</h2>
<div class="wide box">
<h3>
Lineup
</h3>
<%= form_for @match do |f| %>
<%= render :partial => "lineup", :locals => {:contester => @contester} %>
<p>
<%= f.submit "Save" %>
</p>
<% end %>
</div>
<% if @match.can_update? cuser, [:score1, :score2] %>
<div class="wide box">
<%= form_for(@match) do |f| %>
<h3>
Scoring
</h3>
<%= f.error_messages %>
<p>
<%= f.label :score1, "Score" %><br />
<%= f.text_field :score1, :size => 1 %>
<%= f.text_field :score2, :size => 1 %>
</p>
<p>
<%= f.submit 'Submit' %>
</p>
<% end %>
</div>
<% end %>
<%= link_to "Back", @match %>