Skip to content
This repository has been archived by the owner on Jan 6, 2023. It is now read-only.
This repository has been archived by the owner on Jan 6, 2023. It is now read-only.

Endpoint /roles should return a relational list of users in the role. #641

Closed
shealavington opened this issue Dec 8, 2018 · 0 comments
Closed
Labels
enhancement New feature or request

Comments

@shealavington
Copy link

Feature Request

When visiting the endpoint /roles, and append ?fields=*.* It should return a list of users associated with the role.

This is because if you visit /users/me and append ?fields=*.*, it returns a list of roles associated with the user.

What problem does this feature solve?

I had some confusion where visiting /users?fields="*.* was returning me an array of a M2M field, however when doing the same on the roles field, I wasn't getting the expected outcome. (/roles?fields="*.*). (Ben helped to explain that confusion haha)

For example: if you had a site, where you would like to list a group of people, [Writers, Editors, Singers], you could visit the endpoint /roles?fields=*.* then list each person based on their role.

How do you think this should be implemented?

Ben pointed out, it probably just needs adding to the boilerplate schema

Would you be willing to work on this?

I'm willing to help as much as possible.

@benhaynes benhaynes added the enhancement New feature or request label Dec 9, 2018
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants