rubyforgood / share_christmas

Share Your Holiday Application
4 stars 3 forks source link

Organization: Add or Remove Administrators #96

Closed craig-riecke closed 8 years ago

craig-riecke commented 8 years ago

Route: GET /organizations/orgId?admins

List all admins of current org. Admins will have a Remove button/link next to them, which will DELETE /memberships/memberId, that removes their membership record and removes the role OrgAdmin from their user record. An Add button will go to GET /organizations/orgId/new_admin

craig-riecke commented 8 years ago

Move route to

GET /users?organization=orgId

To make it more "Rails-y"

craig-riecke commented 8 years ago

It seems that the Org Admin role is actually better put on the Membership model than the User model. A user can be a member of many organizations, but they may only be an Admin of none/some of them.

If that makes sense, the Org Admin screen should be probably be at:

GET /memberships/index?organization=orgId&org_admin=true

craig-riecke commented 8 years ago

Implemented in #102