diff --git a/app/models/profile.rb b/app/models/profile.rb index d4637ea..c6805c2 100644 --- a/app/models/profile.rb +++ b/app/models/profile.rb @@ -99,6 +99,16 @@ class Profile < ActiveRecord::Base } scope :no_templates, {:conditions => {:is_template => false}} + #FIXME make this test + named_scope :newer_than, lambda { |reference_id| + {:conditions => ["profiles.id > #{reference_id}"]} + } + + #FIXME make this test + named_scope :older_than, lambda { |reference_id| + {:conditions => ["profiles.id < #{reference_id}"]} + } + def members scopes = plugins.dispatch_scopes(:organization_members, self) scopes << Person.members_of(self) -- libgit2 0.21.2