[CP staging] Stay on chat report when tracking distance from report preview - #71937
Conversation
|
@dominictb Please copy/paste the Reviewer Checklist from here into a new comment on this PR and complete it. If you have the K2 extension, you can simply click: [this button] |
Codecov Report✅ All modified and coverable lines are covered by tests. 📢 Thoughts on this report? Let us know! |
|
✋ This PR was not deployed to staging yet because QA is ongoing. It will be automatically deployed to staging after the next production release. |
[CP staging] Stay on chat report when tracking distance from report preview (cherry picked from commit 876573d) (cherry-picked to staging by lakchote)
|
🚀 Cherry-picked to staging by https://github.com/lakchote in version: 9.2.24-1 🚀
|
|
🚀 Cherry-picked to staging by https://github.com/lakchote in version: 9.2.26-0 🚀
|
|
🚀 Deployed to production by https://github.com/lakchote in version: 9.2.26-7 🚀
|
|
🚀 Cherry-picked to staging by https://github.com/lakchote in version: 9.2.27-0 🚀
|
|
🚀 Deployed to production by https://github.com/lakchote in version: 9.2.27-6 🚀
|
Explanation of Change
This PR fixes a navigation issue introduced in #71005 where creating a distance expense from the report preview in a workspace chat would incorrectly navigate to the expense report instead of staying on the workspace chat.
The root cause was that the
startDistanceRequestcall inMoneyRequestReportPreviewContent.tsxwas missing thebackToReportparameter. This parameter tells the app where to navigate back to after creating the expense. When creating an expense from the workspace chat's report preview, we should pass thechatReportIDto ensure users stay on the workspace chat after creating the expense.Fixed Issues
$ #71929
PROPOSAL: N/A (This is an internal fix for a bug introduced in #71005)
2025-10-06_14-54-51.mp4
Offline tests
N/A - This is a navigation fix that doesn't involve offline behavior
QA Steps
Same as tests
PR Author Checklist
### Fixed Issuessection aboveTestssectionOffline stepssectionQA stepssectioncanBeMissingparam foruseOnyxtoggleReportand notonIconClick)src/languages/*files and using the translation methodSTYLE.md) were followedAvatar, I verified the components usingAvatarare working as expected)StyleUtils.getBackgroundAndBorderStyle(theme.componentBG))npm run compress-svg)Avataris modified, I verified thatAvataris working as expected in all cases)Designlabel and/or tagged@Expensify/designso the design team can review the changes.ScrollViewcomponent to make it scrollable when more elements are added to the page.mainbranch was merged into this PR after a review, I tested again and verified the outcome was still expected according to theTeststeps.Screenshots/Videos
I only tested on web as shown above because the change is platform independent.
Android: Native
Android: mWeb Chrome
iOS: Native
iOS: mWeb Safari
MacOS: Chrome / Safari
MacOS: Desktop