Gather Admin: #<%= @gather.id %>

Restart Gather

<%= form_for(@gather, html: { class: 'square' }) do |f| %> <%= render 'shared/errors', messages: @gather.errors.full_messages %> <%= f.hidden_field :admin %>
<%= f.label :captain1 %> <%= f.select :captain1_id, @gather.gatherers.collect{|c| [c, c.id]} %>
<%= f.label :captain2 %> <%= f.select :captain2_id, @gather.gatherers.collect{|c| [c, c.id]} %>
<%= f.submit 'Restart Gather' %>
<% end %>

Change Turns

<%= form_for(@gather, html: { class: 'square' }) do |f| %> <%= render 'shared/errors', messages: @gather.errors.full_messages %>
<%= f.label :turn %> <%= f.select :turn, ['Team 1', 'Team 2'] %>
<%= f.submit 'Change Turn' %>
<% end %>

Replace Players

<% if @gather.gatherers.first %> <%= form_for(@gather.gatherers.first, html: { class: 'square' }) do |f| %>
<%= f.label :id, "Select Player" %> <%= f.select :id, @gather.gatherers.collect{|g| [g.user, g.id]} %>
<%= f.label :username, "Replace with:" %> <%= f.text_field :username %>
<%= f.submit 'Replace Player' %>
<% end %> <% end %>

Start New

<%= form_for Gather.new do |f| %> <% f.object.category = @gather.category %> <%= f.hidden_field :category_id %>
<%= f.submit "Start New Gather (#{f.object.category})" %>
<% end %>