-
Notifications
You must be signed in to change notification settings - Fork 48
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
Peterson implement toast when user is already in a team #2332
Peterson implement toast when user is already in a team #2332
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The functionality works when a new team is assigned to the user, and then the user is added to the same team again.
However, I am facing issues when the user is added again to the existing team. There is no response in the UI. Please check the video.
PR.2332.mp4
In the video, "The Test 2024" was the new team just added, while the "FanYangTestTeam" was the team the user was already in.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hi Peterson,
I found 2 test cases in this PR, I've shown them below.
- Test case 1 :
- Find a team that a user is already assigned to
- Try adding yourself into the same team
- The warning shows up
- Here, I'm part of team 2023 and I try to add myself
- I get the warning
- Test case 1 works as expected
- Test case 2 :
- Assign yourself a new team
- Click confirm
- The user is not added into that team until the user click save changes at the bottom of the page
- But the assign team modal stays open, This needs to be closed after the user clicks confirm.
- Since it stays open, if I click confirm again in the assign team modal, there is no response from the UI, nor is there any API call running.
- I clicked confirm here, got the team assigned but the modal stayed open
- Even if I keep clicking confirm after that, there is no response anywhere
- Test case 2 is the issue
This may be linked to the previous user's requested changes. Please verify and update. If this is not linked to your task, I can raise a bug.
b055328
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
After your changes, I have reviewed the PR again. The problem I faced earlier was solved; I got the Toast error message for adding the user to an existing team. However, there is a new issue when I try to assign the user to a new team (which still needs to be added to the team list); I am facing errors. This was not the issue in my previous review. So your changes might have caused it.
I have attached the video for you to look over.
PR.2332-1.mp4
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hi Peterson,
I found 2 test cases in this PR, I've shown them below.
- Test case 1 :
- Find a team that a user is already assigned to
- Try adding yourself into the same team
- The warning shows up
- Here, I'm part of team 2023 and I try to add myself
- I get the warning
- Test case 1 works as expected
- Test case 2 :
- Assign yourself a new team
- Click confirm
- The user is not added into that team until the user click save changes at the bottom of the page
- But the assign team modal stays open, This needs to be closed after the user clicks confirm.
- Since it stays open, if I click confirm again in the assign team modal, there is no response from the UI, nor is there any API call running.
- I clicked confirm here, got the team assigned but the modal stayed open
- Even if I keep clicking confirm after that, there is no response anywhere
- Test case 2 is the issue
This may be linked to the previous user's requested changes. Please verify and update. If this is not linked to your task, I can raise a bug.
Hi Peterson,
Test case 2 works as well. Duplicate team cannot be added and that is shown clearly using toast messages. Good work.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The functionality works as expected.
https://github.com/OneCommunityGlobal/HighestGoodNetworkApp/assets/112303944/85a621ca-870e-4bd2-812b-25bd9e74a0be
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
the functionality works correctly. I am able to see the toast when I try to add user in a team they are already in. Thanks!
Screen.Recording.2024-07-19.at.6.05.53.PM.mov
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I have tested this PR. I tested with my account and the feature worked as intended. When trying to add a user to an existing team, the error pop-up will appear.
profile.mp4
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I tested the PR and observed that the toast notification works as expected. When trying to assign a user to a team they are already a part of, a toast notification appears indicating the user is already in the team. Additionally, when assigning the user to a new team, the confirmation toast displays successfully. The feature is functioning correctly, meeting the requirements outlined in the PR description.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hey @peterson337
The PR is Working as Expected
Here is The screenshot
Thank You
I tested the PR and observed that the toast notification works as expected. https://www.loom.com/share/dac7a28bc40d48f0b7daa3cf29e0c502?sid=eb2e97cc-53cd-457a-844f-45bd1e86e67c |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thank you all, merging! |
Description
This PR has been opened to implement a toast notification that will be displayed when a user is added to a team they are already part of.
Related PRS (if any):
None
…
Main changes explained:
The component "AddTeamPopup.jsx" has been modified to implement the toast.
…
How to test:
npm install
and...
to run this PR locallyScreenshots or videos of changes:
Note:
None