bennylope / django-organizations

:couple: Multi-user accounts for Django projects

Home Page:http://django-organizations.readthedocs.org/

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Organizations with multiple owners

brauhausdc opened this issue · comments

I'm still working my way through getting organizations implemented in my project. More a question, but I didn't see any specific way to do this - and it may be useful. I'd like to be able to have multiple "owners" or some other "admin" functionality so that the organization doesn't have to be infinitely tied to a specific user - users come and go, organizations (hopefully) persist.

There are a couple of issues here that are distinct: (a) organization "owner" and (b) organization members with different permission levels.

Ownership

A single organization owner is a [fairly] fundamental part of the architecture at this point. It's present due to the needs of early projects that used this library and it's a general pattern that this library borrowed from a lot of other SaaS and account based services, where there's often one admin user who has "ultimate" rights. In such a case there may be multiple admins, but only the "owner" can, for example, delete the account.

Could it be changed? Yes! I have no principled opposition to removing the constraint of one organization owner per organization, as long as it's backwards compatible.

Admin users and user types

Do you have to make use of the owner concept in your code? No! The abstract models are designed to account for all kinds of other use cases, such as adding "user types" to the custom OrganizationUser model in your project. In such a case you would still be required to have an OrganizationOwner model of your own, but there's no hard requirement that you make use of it.