feat: [FC-0099] Add a new role to a library member (#9)

* refactor: support components as action & connect API to add roles to users

* fix: the value of LIBRARY_AUTHZ_SCOPE was misspelled

* feat: add role assignment functionality with modal and trigger components

* feat: add success toast message for role assignment and update user management logic

* refactor: update handleAddRole to display all roles

* refactor: group under AssignNewRoleModal

* test: add unit tests for AssignNewRoleModal and AssignNewRoleTrigger components

* fix: remove duplicated exports after rebase

---------

Co-authored-by: Diana Olarte <diana.olarte@edunext.co>
This commit is contained in:
Brayan Cerón
2025-10-21 19:19:48 -05:00
committed by GitHub
parent 52fbb7ea9d
commit 2259a453ce
8 changed files with 684 additions and 3 deletions

View File

@@ -24,7 +24,6 @@ export interface AssignTeamMembersRoleRequest {
scope: string;
}
// TODO: replece api path once is created
export const getTeamMembers = async (object: string): Promise<TeamMember[]> => {
const { data } = await getAuthenticatedHttpClient().get(getApiUrl(`/api/authz/v1/roles/users/?scope=${object}`));
return camelCaseObject(data.results);