-<% %>
-<h1>Information On <%= @election.name %></h1>
+<%= render_partial 'progress', 'review' %>
+<h1>Vote Information</h1>
+
+<% if @election.active? %>
+ <div id="status">Vote is in currently in progress. Return to
+ this page for results on <%= @election.enddate %>.</div>
+<% elsif @election.done? %>
+ <div id="status">Election is finished. <%= link_to "View results",
+ :action => 'results', :id => @election.id %>.</div>
+<% end %>
+
+<h2>Overview</h2>
+
+<p><strong>Summary</strong></p>
+
+<blockquote>
+<%= h(@election.name) %>
+</blockquote>
-<h2>Election Overview</h2>
-
<p><strong>Description</strong></p>
<blockquote>
<%= h(@election.description) %>
</blockquote>
-<p><strong>Election End Date</strong></p>
+<p><strong>End Date</strong></p>
<blockquote>
<%= @election.enddate %>
</blockquote>
-<p><%= link_to "Edit election overview.", :action => 'edit', :id => @election.id %></p>
+<% unless @election.active %>
+<p><%= link_to "Edit overview.", :action => 'edit', :id => @election.id %></p>
+<% end %>
<h2>Candidates</h2>
-
+<% %>
<% unless @election.candidates.empty? %>
<%= render :partial => 'candidate_list' %>
+ <% unless @election.active %>
<p><%= link_to "Add, remove, or edit candidates.", :action => 'edit_candidates', :id => @election.id %></p>
+ <% end %>
<% else %>
- <p><em>There are currently no candidates registered for this election.
- <%= link_to "Add some!", :action => 'edit_candidates', :id => @election.id %></em></p>
+ <p><em>There are currently no candidates registered. <%= link_to "Add some!", :action => 'edit_candidates', :id => @election.id unless @election.active %></em></p>
<% end %>
<% unless @election.voters.empty? %>
<%= render :partial => 'voter_list' %>
- <%= link_to "Add or remove voters.", :action => 'edit_voters', :id => @election.id %></em></p>
+ <%= link_to "Add or remove voters.", :action => 'edit_voters', :id => @election.id unless @election.active %></em></p>
<% else %>
- <p><em>There are currently no voters registered for this election.
- <%= link_to "Add some!", :action => 'edit_voters', :id => @election.id %></em></p>
+ <p><em>There are currently no voters registered. <%= link_to "Add some!", :action => 'edit_voters', :id => @election.id unless @election.active %></em></p>
<% end %>
-<h2>Start Election</h2>
-
-<% if @election.start_blockers.length > 0 %>
- <p>Your election cannot be started for the following reasons:</p>
- <ul>
- <% for reason in @election.start_blockers %>
- <li><%= reason %></li>
+<% unless @election.active? %>
+ <h2>Start Election</h2>
+
+ <% if @election.start_blockers.length > 0 %>
+ <p>Your vote cannot be started for the following reasons:</p>
+ <ul>
+ <% for reason in @election.start_blockers %>
+ <li><%= reason %></li>
+ <% end %>
+ </ul>
+ <% else %>
+ <p>Please check everything carefully on this page before starting this
+ vote. Once you begin the vote, you will <em>not</em> be able to add or
+ change candidates, modify the voting lists, or change the end
+ time.</p>
+
+ <p>When you begin the vote, the following will happen:</p>
+
+ <ul>
+ <li>The vote will be "frozen" so that further edits to the
+ candidate list and voting list cannot occur.</li>
+ <li>All voters will be emailed notifying them that the vote has
+ begun and of their unique login token.</li>
+ </ul>
+
+ <%= button_to 'Start Election!', :action => 'start_election', :id => @election.id %>
<% end %>
- </ul>
-<% else %>
-<p>Please check eveything carefully on this page before starting this
-election. Once you begin the election, you will <em>not</em> be able to
-add or change candidates, modify the voting lists, or change the
-election end time.</p>
-
-<p>When you begin the election, the following will happen:</p>
-
-<ul>
- <li>The election will be "frozen" so that further edits to the
- candidate list and voting list cannot occur.</li>
- <li>All voters will be emailed notifying them that the election has
- begun and of their unique login token.</li>
-</ul>
-
-<%= button_to 'Start Election!', :action => 'start_election', :id => @election.id %>
<% end %>