-
Notifications
You must be signed in to change notification settings - Fork 3k
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
[HOLD for payment - C+ only] [$1000] Workspace - Remove button is displayed active upon selecting admin to be deleted from workspace #20719
Comments
Triggered auto assignment to @NicMendonca ( |
Bug0 Triage Checklist (Main S/O)
|
ProposalPlease re-state the problem that we are trying to solve in this issue.In workspace members page, the remove button is active when admin/logged in user is selected for removal which is not allowed. What is the root cause of that problem?The remove button is disabled only when there are no selected members. The condition for checking if admin/logged in user is selected is not added. App/src/pages/workspace/WorkspaceMembersPage.js Lines 454 to 461 in b089bde
What changes do you think we should make in order to solve the problem?We need to add a new condition here to disable the button when either the logged in user or admin or both are selected. For that, we can use the following condition - isDisabled={this.state.selectedEmployees.length === 0 || _.some(this.state.selectedEmployees, member => member === this.props.policy.owner || member === this.props.session.email)} We can create a new function for this to make it more readable. What alternative solutions did you explore? (Optional)NA |
Currently, We are facing this bug. My proposal will work well after this issue is resolved ProposalPlease re-state the problem that we are trying to solve in this issue.Workspace - Remove button is displayed active upon selecting admin to be deleted from workspace What is the root cause of that problem?
We are checking that if this.state.selectedEmployees.length === 0 we will disable the remove button What changes do you think we should make in order to solve the problem?We also should disable remove button if there is any error like that
It is similar to the check we did when clicking the remove button App/src/pages/workspace/WorkspaceMembersPage.js Lines 197 to 200 in 862955c
ResultScreen.Recording.2023-06-14.at.14.32.15.mov |
@kbecciv just to confirm, under the |
@NicMendonca Corrected, sorry for confusion |
Job added to Upwork: https://www.upwork.com/jobs/~01b6a900eb33013827 |
Current assignee @NicMendonca is eligible for the External assigner, not assigning anyone new. |
Triggered auto assignment to Contributor-plus team member for initial proposal review - @sobitneupane ( |
ProposalPlease re-state the problem that we are trying to solve in this issue.Workspace/Memeber - Remove button is displayed active upon selecting admin to be deleted from workspace What is the root cause of that problem?Remove buttons
What changes do you think we should make in order to solve the problem?We should check if And I passed the
`toggleUser(accountID, pendingAction, role) {
And then, update the remove button's
What alternative solutions did you explore? (Optional)Maybe, I can use session value to check if admin user selected. Result VideoScreen.Recording.2023-06-15.at.5.36.45.PM.mov |
📣 @jaytechfulldev! 📣
|
Contributor details |
✅ Contributor details stored successfully. Thank you for contributing to Expensify! |
Thanks for proposal everyone. Proposal from @dukenv0307 looks good to me. 🎀 👀 🎀 C+ reviewed |
Triggered auto assignment to @cead22, see https://stackoverflow.com/c/expensify/questions/7972 for more details. |
@sobitneupane @NicMendonca the proposal from @dukenv0307 looks good, but it doesn't feel like a complete solution, because we'll end up with a checkbox for the admin that doesn't do anything, and that isn't checked when Select All is checked, and that alone feels like a bug. I think it would be better if we didn't show a checkbox for the admin, or if we showed it disabled. What do you think? cc @shawnborton |
@cead22 Can you check my proposal? I checked if Admin selected and even if user checked "All". |
I like the idea of showing it disabled. |
@shawnborton @cead22 A little curios, if we always disable the admin checkbox, Users won't know why can't click the checkbox. Currently, when clicking the admin checkbox we are showing an error message to to notify to user |
Triggered auto assignment to @Christinadobrzyn ( |
This comment was marked as duplicate.
This comment was marked as duplicate.
@Christinadobrzyn I am going OOO until Wednesday. Can you watch this while I am away? I'll unassign you when I am back. Thank you! |
Looks like we're reviewing the PR moving this to weekly |
Based on my calculations, the pull request did not get merged within 3 working days of assignment. Please, check out my computations here:
On to the next one 🚀 |
|
The solution for this issue has been 🚀 deployed to production 🚀 in version 1.3.35-5 and is now subject to a 7-day regression period 📆. Here is the list of pull requests that resolve this issue: If no regressions arise, payment will be issued on 2023-07-10. 🎊 After the hold period is over and BZ checklist items are completed, please complete any of the applicable payments for this issue, and check them off once done.
As a reminder, here are the bonuses/penalties that should be applied for any External issue:
|
BugZero Checklist: The PR fixing this issue has been merged! The following checklist (instructions) will need to be completed before the issue can be closed:
|
This was a design decision to allow users to select admin back then. So, I don't think this could have been caught earlier.
Yes
|
Regression Test Proposal
Do we agree 👍 or 👎 |
Payment Requested on Expensify. |
@dukenv0307 can you please apply to the job? |
@NicMendonca I applied, thank you! |
@dukenv0307 you've been paid! |
@sobitneupane keep us posted! |
as per this SO, I can close! @sobitneupane you'll be paid shortly! |
If you haven’t already, check out our contributing guidelines for onboarding and email contributors@expensify.com to request to join our Slack channel!
Action Performed:
1, Login to NewDot
2. Go to Workspace -> Members -> Invite
3. Select admin account
Expected Result:
Remove button should not look active
Actual Result:
Remove button is displayed active upon selecting admin to be deleted from workspace
Workaround:
Unknown
Platforms:
Which of our officially supported platforms is this issue occurring on?
Version Number: 1.3.27.2
Reproducible in staging?: yes
Reproducible in production?: yes
If this was caught during regression testing, add the test name, ID and link from TestRail:
Email or phone of affected tester (no customers):
Logs: https://stackoverflow.com/c/expensify/questions/4856
Notes/Photos/Videos: Any additional supporting documentation
Bug6091696_video_58.mp4
Expensify/Expensify Issue URL:
Issue reported by: Applause - Internal Team
Slack conversation:
View all open jobs on GitHub
Upwork Automation - Do Not Edit
The text was updated successfully, but these errors were encountered: