code0-tech / sagittarius

The orchestrating backend for the Code0 application
4 stars 0 forks source link

Create and assign role with assign_role_abilities permission on organization creation #132

Closed Taucher2003 closed 4 months ago

Taucher2003 commented 4 months ago

Currently, when an organization is created, the user is added as a member, but doesn't get any permissions in the organization.

To change that, the Organizations::CreateService should create an OrganizationRole with the :assign_role_abilities ability and the member should be added to this role.

https://github.com/code0-tech/sagittarius/blob/main/app/services/organizations/create_service.rb