-
Notifications
You must be signed in to change notification settings - Fork 2.9k
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
[Distance rates] Category - Cannot cancel the category selection in distance rates settings #38673
Comments
👋 Friendly reminder that deploy blockers are time-sensitive ⏱ issues! Check out the open `StagingDeployCash` deploy checklist to see the list of PRs included in this release, then work quickly to do one of the following:
|
Triggered auto assignment to @Beamanator ( |
We think that this bug might be related to #wave-collect - Release 1 |
@Beamanator FYI I haven't added the External label as I wasn't 100% sure about this issue. Please take a look and add the label if you agree it's a bug and can be handled by external contributors |
ProposalPlease re-state the problem that we are trying to solve in this issue.Cannot cancel the category selection in distance rates settings What is the root cause of that problem?We are not checking if if the selected category is the same as the already existing one
What changes do you think we should make in order to solve the problem?inside setNewCategory we need to check if the selected category is the same as the already existing one const isSelectedCategory = category.text === defaultCategory;
const updatedCategory = isSelectedCategory ? '' : category.text; as we do here App/src/pages/iou/request/step/IOURequestStepCategory.js Lines 90 to 92 in b527962
const setNewCategory = (category: ListItem) => {
const isSelectedCategory = category.text === defaultCategory;
const updatedCategory = isSelectedCategory ? '' : category.text;
Policy.setPolicyDistanceRatesDefaultCategory(policyID, customUnit, {...customUnit, defaultCategory: updatedCategory});
}; POC video: 20240320_152506.mp4What alternative solutions did you explore? (Optional) |
I will fix this in the next PR that adds another screen to distance rates feature. Currently its in draft state #38237 |
Current assignee @trjExpensify is eligible for the Bug assigner, not assigning anyone new. |
Related discussion here: https://expensify.slack.com/archives/C036QM0SLJK/p1710945911418889?thread_ts=1710800247.591739&cid=C036QM0SLJK This isn't a blocker, demoting it. @MrMuzyk is going to fix it in the follow-up PR. |
The PR has been merged and C+ payment is handled elsewhere, I believe we can close this issue now as no further steps are required, thanks @MrMuzyk ! |
If you haven’t already, check out our contributing guidelines for onboarding and email [email protected] to request to join our Slack channel!
Version Number: 1.4.55-0
Reproducible in staging?: Y
Reproducible in production?: N
If this was caught during regression testing, add the test name, ID and link from TestRail: N/A
Issue reported by: Applause - Internal Team
Issue found when executing PR #38060
Action Performed:
Precondition:
Expected Result:
User can unselect the category in distance rates settings
Actual Result:
Cannot cancel the category selection in distance rates settings
Workaround:
Unknown
Platforms:
Which of our officially supported platforms is this issue occurring on?
Screenshots/Videos
Add any screenshot/video evidence
Bug6420487_1710941440438.bandicam_2024-03-20_15-13-08-247.mp4
View all open jobs on GitHub
The text was updated successfully, but these errors were encountered: