Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[FIX] Prevent users to edit an existing role when adding a new one with the same name used before. #22407

Merged
merged 26 commits into from
Sep 24, 2021

Conversation

dougfabris
Copy link
Member

@dougfabris dougfabris commented Jun 18, 2021

Proposed changes (including videos or screenshots)

before

Peek 2021-07-13 16-31

after

Peek 2021-07-13 16-34

Issue(s)

Steps to test or reproduce

  • Go to admin and permissions
  • Try to create a role with the same name as another one already created
  • You're going to see the error toast message

Notes for QA

We replaced all of the methods to manipulate the roles. Would be nice to include some tests like:

  • Create a new role
  • Update a role
  • Delete a role
  • Check if it's possible to check the users in the role

Further comments

@dougfabris dougfabris marked this pull request as ready for review July 13, 2021 19:14
@dougfabris dougfabris requested review from pierre-lehnen-rc and a team July 13, 2021 19:15
@dougfabris dougfabris changed the title [FIX] Role Editing form doesn't update after saving changes. [FIX] Prevent user to edit an existing role when add a new one if a name used before. Jul 13, 2021
@dougfabris dougfabris changed the title [FIX] Prevent user to edit an existing role when add a new one if a name used before. [FIX] Prevent users to edit an existing role when adding a new one with the same name used before. Jul 13, 2021
@pierre-lehnen-rc
Copy link
Contributor

The tests are going to pass once #22799 is merged;

app/api/server/v1/roles.js Outdated Show resolved Hide resolved
app/api/server/v1/users.js Outdated Show resolved Hide resolved
@pierre-lehnen-rc pierre-lehnen-rc merged commit ed04c71 into develop Sep 24, 2021
@pierre-lehnen-rc pierre-lehnen-rc deleted the fix/roles.update branch September 24, 2021 03:02
@sampaiodiego sampaiodiego mentioned this pull request Oct 1, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants