diff --git a/app/models/profile.rb b/app/models/profile.rb index 5bceef5..96930dc 100644 --- a/app/models/profile.rb +++ b/app/models/profile.rb @@ -81,6 +81,16 @@ class Profile < ActiveRecord::Base named_scope :templates, {:conditions => {:is_template => true}} named_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