]> projects.mako.cc - selectricity-live/blob - app/views/voter/_sortable_vote.rhtml
41544827f8f7c26cc8dc4dfe53ac6058970c1070
[selectricity-live] / app / views / voter / _sortable_vote.rhtml
1 <% %>
2 <div id="sortable_list">
3 <ol id="rankings-list">
4   <% for ranking in @voter.vote.rankings %>
5     <li class="moveable" id="ranking_<%= ranking.candidate.id %>">
6       <%=h ranking.candidate.name.capitalize %></li>
7   <% end %>
8 </ol>
9 </div>
10
11 <div class="clearbox"></div>
12
13 <%= sortable_element 'rankings-list',
14     :url => { :action => "sort_candidates", :id => @voter.vote.id },
15     :complete => visual_effect(:highlight, 'rankings-list') %>

Benjamin Mako Hill || Want to submit a patch?