Commit 6963b91cbc3fbd432b50cca9b8a9dd5df7769cd1

Authored by MoisesMachado
1 parent aca3cda8

ActionItem85: fixed a bug on witch it was listing persons on my enterprises

git-svn-id: https://svn.colivre.coop.br/svn/noosfero/trunk@771 3f533792-8f58-4932-b0fe-aaf55b0a4547
Showing 1 changed file with 1 additions and 1 deletions   Show diff stats
app/models/person.rb
... ... @@ -26,7 +26,7 @@ class Person < Profile
26 26 :all,
27 27 :conditions => self.class.conditions_for_profiles(conditions, self),
28 28 :joins => "LEFT JOIN role_assignments ON profiles.id = role_assignments.resource_id AND role_assignments.resource_type = \'#{Profile.base_class.name}\'",
29   - :select => 'profiles.*').uniq
  29 + :select => 'profiles.*').uniq.select{|p|p.class == Enterprise}
30 30 end
31 31  
32 32 def info
... ...