2014-03-23 00:22:25 +00:00
|
|
|
<h1>
|
|
|
|
New challenge
|
|
|
|
</h1>
|
|
|
|
|
|
|
|
<div class="wide box">
|
|
|
|
<%= form_for @challenge do |f| %>
|
|
|
|
<%= f.error_messages %>
|
|
|
|
<%= f.hidden_field :contester1_id %>
|
|
|
|
<%= f.hidden_field :contester2_id %>
|
|
|
|
|
|
|
|
<div class="contentWide">
|
2015-05-16 13:54:14 +00:00
|
|
|
<% if @challenge.errors.empty? %>
|
2014-03-23 00:22:25 +00:00
|
|
|
<h3 class="center">
|
|
|
|
<%= namelink @challenge.contester1.team %>
|
|
|
|
vs
|
|
|
|
<%= namelink @challenge.contester2.team %>
|
|
|
|
</h3>
|
|
|
|
<p>
|
|
|
|
<%= f.label :details, "Information for the opponent" %><br />
|
|
|
|
<%= f.text_area :details, :cols => 40, :rows => 7 %>
|
|
|
|
</p>
|
|
|
|
<p>
|
|
|
|
<%= f.submit 'Create' %>
|
|
|
|
</p>
|
|
|
|
<% end %>
|
|
|
|
</div>
|
|
|
|
<% end %>
|
|
|
|
</div>
|
|
|
|
|
|
|
|
<%= link_to 'Back', @challenge.contester1.contest %>
|