]> projects.mako.cc - selectricity/blobdiff - app/models/ranking.rb
Changed the Selectricity header into a link, and modified the config/routes.rb file...
[selectricity] / app / models / ranking.rb
old mode 100644 (file)
new mode 100755 (executable)
index ba021a9..5ef0575
@@ -1,6 +1,7 @@
 class Ranking < ActiveRecord::Base
   belongs_to :candidate
   belongs_to :vote
 class Ranking < ActiveRecord::Base
   belongs_to :candidate
   belongs_to :vote
+  acts_as_list :scope => :vote, :column => :rank
 
   def <=>(other)
     self.rank <=> other.rank
 
   def <=>(other)
     self.rank <=> other.rank

Benjamin Mako Hill || Want to submit a patch?