Initital scaffolding of the website plus initial work on the adding and
[selectricity-live] / app / views / elections / _candidates_form.rhtml
1 <p>Please enter candidates for <strong><%= @election.name %></strong>.</p>
2
3   <ul id="candidates_list">
4      <% @election.candidates.each do |candidate| %>
5        <% @candidate = candidate %>
6        <%= render :partial => 'candidate_line' %>
7      <% end %>
8   </ul>
9
10   <%= form_remote_tag(:update => "candidates_list",
11                       :url => { :action => :add_candidate, :id => @election.id },
12                       :position => "top" ) %>
13
14   <p>New candidate name:
15   <%= text_field_tag :newcandidate %>
16
17   <%= submit_tag "Add" %>
18   <%= end_form_tag %>

Benjamin Mako Hill || Want to submit a patch?