]> projects.mako.cc - selectricity-live/blob - app/views/embed/full_vote.rhtml
fix mispelling in about screen
[selectricity-live] / app / views / embed / full_vote.rhtml
1 <div id="header" style="background-image:url(<%if @top_bar%>
2                                                 <%=url_for @top_bar.public_filename%>)
3                                                 <% else %>
4                                                 /images/embed_basic_bg.png)
5                                                 <% end %>">
6 <%= link_to '<img id="header_icon" src="/images/embed_header_icon.png" />',
7             {:controller => 'front'}, {:target => "_parent"} %><h2>Vote Now</h2>
8 </div>
9
10 <div id="voting-box" height="<%=(@election.candidates.length + 2)*53 %>px">
11         
12         <%= render :partial => '/embed/backdrop' %>
13         <ul id="rankings-list">
14       <% @voter.vote.rankings.each do |ranking| %>
15                 <li class="ranking" id="ranking_<%= ranking.candidate.id %>">
16                         <img alt="<%= white_list ranking.candidate.name %>"
17                  src="<% if ranking.candidate.picture -%>
18                       <%= url_for ranking.candidate.picture.public_filename(:thumb) -%>
19                                           <% elsif @default_image %>
20                                           <%= url_for @default_image.public_filename %>
21                       <%- else -%>
22                      /images/default_icon.png
23                      <%- end %>" />
24                         <p class="ranking-info">
25             <strong><%= white_list ranking.candidate.name %></strong><br />
26             <%= white_list ranking.candidate.description %></p>
27                 </li>
28       <% end %>
29         </ul>
30         
31         <div style="clear:both;"></div>
32         
33         <div id="voting-bottom" style="
34         <% if @bottom_bar %>
35         background-image:url(<%= url_for @bottom_bar.public_filename %>)
36         <% elsif @election.candidates.length%2 == 0 %>
37         background-image:url(/images/bottom_dark.png)
38         <%else%>
39         background-image:url(/images/bottom_light.png)
40         <%end%>" >
41                 <div id="container">
42                         <a href="<%= url_for :action => :confirm, :id => @password, :embed => 'true' %>"><h2 id="submit_vote_button">Submit Vote</h2></a>
43                         <p><b>Drag and drop</b> to rank the choices.</p>
44                 </div>
45         </div>
46 </div>
47
48 <%= sortable_element 'rankings-list',
49     :url => { :action => "sort_candidates", :id => @voter.vote.id } %>
50

Benjamin Mako Hill || Want to submit a patch?