Make admin members
This commit is contained in:
parent
b1a52cc872
commit
b8876ba023
3 changed files with 7 additions and 6 deletions
|
@ -112,6 +112,10 @@ class Organization(models.Model):
|
|||
def get_contests_url(self):
|
||||
return reverse("organization_contests", args=(self.id, self.slug))
|
||||
|
||||
def save(self, *args, **kwargs):
|
||||
self.members.add(*self.admins.all())
|
||||
super(Organization, self).save(*args, **kwargs)
|
||||
|
||||
class Meta:
|
||||
ordering = ["name"]
|
||||
permissions = (
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue