Eliminated use of scenarios plugin

It doesn't work on Rails 2.3.5
This commit is contained in:
Eric Allen 2009-12-08 13:13:21 -05:00
parent d1fc119e2d
commit 6d3770c5fb
42 changed files with 24 additions and 1576 deletions

View file

@ -17,7 +17,7 @@ class Todo < ActiveRecord::Base
after_save :save_predecessors
named_scope :active, :conditions => { :state => 'active' }
named_scope :not_completed, :conditions => ['NOT (state = ? )', 'completed']
named_scope :not_completed, :conditions => ['NOT (todos.state = ? )', 'completed']
named_scope :are_due, :conditions => ['NOT (todos.due IS NULL)']
STARRED_TAG_NAME = "starred"