Skip to content

Commit

Permalink
Re-added helper function to get groups ids only.
Browse files Browse the repository at this point in the history
  • Loading branch information
flekschas committed Jun 29, 2015
1 parent d19b52b commit 095ab8f
Showing 1 changed file with 10 additions and 0 deletions.
10 changes: 10 additions & 0 deletions refinery/core/models.py
Original file line number Diff line number Diff line change
Expand Up @@ -286,6 +286,16 @@ def get_groups(self, changeonly=False, readonly=False):

return groups

def get_group_ids(self, changeonly=False, readonly=False):
groups = get_groups_with_perms(self)

ids = []

for group in groups:
ids.append(group.id)

return ids

# TODO: clean this up
def is_public(self):
permissions = get_groups_with_perms(self, attach_perms=True)
Expand Down

0 comments on commit 095ab8f

Please sign in to comment.