Fix errors when viewing results as election creator before election close.
[selectricity] / app / views / common / _methodinfo_condorcet.rhtml
index 5fb29e05fc22f33e0f0bf9e47da2e70599099a3d..1c2a382202b9f2e1a3b1e30e8aba4799f2c8e30f 100644 (file)
@@ -13,12 +13,17 @@ another Condorcet system.</p>
 
 <% candidates = @election.ssd_result.ranked_candidates.flatten -%>
 <% if candidates.size <= 7 -%>
-  <%= render_partial 'common/pref_tables' %>
+  <%= render :partial => 'common/pref_tables' %>
 <% else %>
 
   There are too many candidates in your elections to show the result
-  tables.  <%= link_to "Click here", { :action => 'pref_tables', :id =>
-  @voter.password }, :popup => [] %> to view details.
+  tables. 
+
+  <% if not @election.class == QuickVote %>
+    <%= link_to "Click here", { :action => 'pref_tables', :id => @election.id }, :popup => [] %>
+    to view details.
+  <% end %>
+  
 
 <% end -%>
 

Benjamin Mako Hill || Want to submit a patch?