Skip to content

[Due for payment 2025-06-05] [Due for payment 2025-06-04] [$250] Unreported per diem expense can be submitted to user, incorrect redirection with RHP back button on the confirmation page #62727

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

Closed
8 tasks done
jponikarchuk opened this issue May 24, 2025 · 16 comments · Fixed by #62784
Assignees
Labels
Awaiting Payment Auto-added when associated PR is deployed to production Bug Something is broken. Auto assigns a BugZero manager. Engineering External Added to denote the issue can be worked on by a contributor Help Wanted Apply this label when an issue is open to proposals by contributors Weekly KSv2

Comments

@jponikarchuk
Copy link

jponikarchuk commented May 24, 2025

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: 9.1.51-0
Reproducible in staging?: Yes
Reproducible in production?: Unable to check, new feature
If this was caught during regression testing, add the test name, ID and link from TestRail: #58020
Email or phone of affected tester (no customers): [email protected]
Issue reported by: Applause Internal Team
Device used: Mac 15.4 / Chrome
App Component: Money Requests

Action Performed:

Precondition:

  • Log in with Expensifail account.
  • Workspace has per diem rates.
  1. Go to staging.new.expensify.com
  2. Go to workspace chat.
  3. Create two per diem expenses in the workspace chat.
  4. Click on the expense preview to go to expense report.
  5. Click More > Delete.
  6. Delete the report.
  7. Go to self DM.
  8. Click on the per diem expense.
  9. Click on the report header.
  10. Click Submit it to someone.
  11. Select a user (not workspace).
  12. Note that selecting a user is possible when submitting unreported per diem expense.
  13. Click app back button.
  14. Not here page opens.
  15. Click app back button again.
  16. Click Submit it to someone.
  17. Select a workspace.
  18. Click RHP back button on the confirmation page.
  19. Note that RHP back button returns to per diem expense creation flow.

Expected Result:

In Step 12, user should not be able to select another user to submit unreported per diem expense.
In Step 14, RHP back button on confirmation page should return to report details page.

In Step 18, per diem expense receipt should not appear on the confirmation page.
In Step 19, RHP back button on confirmation page should return to report details page.

Actual Result:

In Step 12, user is able to select another user to submit unreported per diem expense.
In Step 14, RHP back button on confirmation page opens not here page when a user is selected.

In Step 18, per diem expense receipt appears on the confirmation page.
In Step 19, RHP back button on confirmation page returns to per diem expense creation flow.

Workaround:

Unknown

Platforms:

  • Android: App
  • Android: mWeb Chrome
  • iOS: App
  • iOS: mWeb Safari
  • iOS: mWeb Chrome
  • Windows: Chrome
  • MacOS: Chrome / Safari
  • MacOS: Desktop

Screenshots/Videos

1.mp4

View all open jobs on GitHub

Upwork Automation - Do Not Edit
  • Upwork Job URL: https://www.upwork.com/jobs/~021927016765901331120
  • Upwork Job ID: 1927016765901331120
  • Last Price Increase: 2025-05-26
Issue OwnerCurrent Issue Owner: @sonialiap
@jponikarchuk jponikarchuk added DeployBlockerCash This issue or pull request should block deployment Bug Something is broken. Auto assigns a BugZero manager. labels May 24, 2025
Copy link

melvin-bot bot commented May 24, 2025

Triggered auto assignment to @sonialiap (Bug), see https://stackoverflow.com/c/expensify/questions/14418 for more details. Please add this bug to a GH project, as outlined in the SO.

@melvin-bot melvin-bot bot added the Daily KSv2 label May 24, 2025
Copy link

melvin-bot bot commented May 24, 2025

Triggered auto assignment to @mjasikowski (DeployBlockerCash), see https://stackoverflowteams.com/c/expensify/questions/9980/ for more details.

Copy link

melvin-bot bot commented May 24, 2025

💬 A slack conversation has been started in #expensify-open-source

@github-actions github-actions bot added Engineering Hourly KSv2 and removed Daily KSv2 labels May 24, 2025
Copy link
Contributor

👋 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:

  1. Identify the pull request that introduced this issue and revert it.
  2. Find someone who can quickly fix the issue.
  3. Fix the issue yourself.

@mjasikowski
Copy link
Contributor

Working on a fix

@mjasikowski
Copy link
Contributor

PR with a partial fix: #62784

@mjasikowski mjasikowski reopened this May 26, 2025
@mjasikowski mjasikowski removed the DeployBlockerCash This issue or pull request should block deployment label May 26, 2025
@mjasikowski
Copy link
Contributor

PR was CP'd to staging, but there's still the back button functionality to fix - I'm opening the issue up for external contributors so they can help with that!

@mjasikowski mjasikowski added the External Added to denote the issue can be worked on by a contributor label May 26, 2025
@melvin-bot melvin-bot bot changed the title Unreported per diem expense can be submitted to user, incorrect redirection with RHP back button on the confirmation page [$250] Unreported per diem expense can be submitted to user, incorrect redirection with RHP back button on the confirmation page May 26, 2025
Copy link

melvin-bot bot commented May 26, 2025

Job added to Upwork: https://www.upwork.com/jobs/~021927016765901331120

@melvin-bot melvin-bot bot added the Help Wanted Apply this label when an issue is open to proposals by contributors label May 26, 2025
Copy link

melvin-bot bot commented May 26, 2025

Triggered auto assignment to Contributor-plus team member for initial proposal review - @jayeshmangwani (External)

@melvin-bot melvin-bot bot added the Daily KSv2 label May 26, 2025
@melvin-bot melvin-bot bot removed the Weekly KSv2 label May 26, 2025
@mkzie2
Copy link
Contributor

mkzie2 commented May 26, 2025

Proposal

Please re-state the problem that we are trying to solve in this issue.

In Step 14, RHP back button on confirmation page opens the subrate page

What is the root cause of that problem?

We always go back to the subrate step if the request is a perdiem request.

if (isPerDiemRequest) {
Navigation.goBack(ROUTES.MONEY_REQUEST_STEP_SUBRATE.getRoute(action, iouType, initialTransactionID, reportID));
return;
}

What changes do you think we should make in order to solve the problem?

We should check if we're moving an unreported expense; we should simply go back to the previous page. We should only go back to the subrate if we're creating a perdiem request.

if (isPerDiemRequest) {
    if (isMovingTransactionFromTrackExpense) {
        Navigation.goBack();
        return;
    }
    Navigation.goBack(ROUTES.MONEY_REQUEST_STEP_SUBRATE.getRoute(action, iouType, initialTransactionID, reportID));
    return;
}

if (isPerDiemRequest) {
Navigation.goBack(ROUTES.MONEY_REQUEST_STEP_SUBRATE.getRoute(action, iouType, initialTransactionID, reportID));
return;
}

OPTIONAL: We can force back to a const route if we're moving unreported perdiem request. Eg: Force back to participant page if the action is share/submit, force back to category step if the action is categorizing.

What specific scenarios should we cover in automated tests to prevent reintroducing this issue in the future?

N/A Navigation issue

What alternative solutions did you explore? (Optional)

We can update the action === CONST.IOU.ACTION.CATEGORIZE condition to isMovingTransactionFromTrackExpense then all moving transaction from track expense actions will take the same behavior.

// We don't need to subscribe to policy_ collection as we only need to check on the latest collection value
if (action === CONST.IOU.ACTION.CATEGORIZE) {
Navigation.goBack();
return;
}
if (isPerDiemRequest) {
Navigation.goBack(ROUTES.MONEY_REQUEST_STEP_SUBRATE.getRoute(action, iouType, initialTransactionID, reportID));
return;
}

Reminder: Please use plain English, be brief and avoid jargon. Feel free to use images, charts or pseudo-code if necessary. Do not post large multi-line diffs or write walls of text. Do not create PRs unless you have been hired for this job.

@mkzie2
Copy link
Contributor

mkzie2 commented May 27, 2025

We can update the action === CONST.IOU.ACTION.CATEGORIZE condition to isMovingTransactionFromTrackExpense then all moving transaction from track expense actions will take the same behavior.

@mjasikowski The issue was external, and the fix here is the same as my solution. Should I get a partial payment here?

@melvin-bot melvin-bot bot added Weekly KSv2 Awaiting Payment Auto-added when associated PR is deployed to production and removed Daily KSv2 labels May 28, 2025
@melvin-bot melvin-bot bot changed the title [$250] Unreported per diem expense can be submitted to user, incorrect redirection with RHP back button on the confirmation page [Due for payment 2025-06-04] [$250] Unreported per diem expense can be submitted to user, incorrect redirection with RHP back button on the confirmation page May 28, 2025
Copy link

melvin-bot bot commented May 28, 2025

Reviewing label has been removed, please complete the "BugZero Checklist".

@melvin-bot melvin-bot bot removed the Reviewing Has a PR in review label May 28, 2025
Copy link

melvin-bot bot commented May 28, 2025

The solution for this issue has been 🚀 deployed to production 🚀 in version 9.1.52-0 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 2025-06-04. 🎊

For reference, here are some details about the assignees on this issue:

Copy link

melvin-bot bot commented May 28, 2025

@jayeshmangwani @sonialiap @jayeshmangwani The PR fixing this issue has been merged! The following checklist (instructions) will need to be completed before the issue can be closed. Please copy/paste the BugZero Checklist from here into a new comment on this GH and complete it. If you have the K2 extension, you can simply click: [this button]

@melvin-bot melvin-bot bot added Weekly KSv2 and removed Weekly KSv2 labels May 29, 2025
@melvin-bot melvin-bot bot changed the title [Due for payment 2025-06-04] [$250] Unreported per diem expense can be submitted to user, incorrect redirection with RHP back button on the confirmation page [Due for payment 2025-06-05] [Due for payment 2025-06-04] [$250] Unreported per diem expense can be submitted to user, incorrect redirection with RHP back button on the confirmation page May 29, 2025
Copy link

melvin-bot bot commented May 29, 2025

The solution for this issue has been 🚀 deployed to production 🚀 in version 9.1.53-7 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 2025-06-05. 🎊

For reference, here are some details about the assignees on this issue:

Copy link

melvin-bot bot commented May 29, 2025

@jayeshmangwani @sonialiap @jayeshmangwani The PR fixing this issue has been merged! The following checklist (instructions) will need to be completed before the issue can be closed. Please copy/paste the BugZero Checklist from here into a new comment on this GH and complete it. If you have the K2 extension, you can simply click: [this button]

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Awaiting Payment Auto-added when associated PR is deployed to production Bug Something is broken. Auto assigns a BugZero manager. Engineering External Added to denote the issue can be worked on by a contributor Help Wanted Apply this label when an issue is open to proposals by contributors Weekly KSv2
Projects
None yet
5 participants