fix: Deeplinking expense creation leads to an expense with 0 amount#57707
Conversation
|
@mananjadhav 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] |
|
Code changes look fine. Will have it tested today. |
|
bump @mananjadhav |
|
I was a bit confused whether we still needed the PR if it's not reproducible (here). I was able to reproduce it a few times, so I think we should still work on it. I'll close it today/tomorrow. |
|
bump here @mananjadhav |
Reviewer Checklist
Screenshots/VideosAndroid: Nativeandroid-deep-linking-expense.movAndroid: mWeb Chromemweb-chrome-deep-linking-expense.moviOS: Nativeios-deep-linking-expense.moviOS: mWeb Safarimweb-safari-deep-linking-expense.movMacOS: Chrome / Safariweb-deep-linking-expense.movMacOS: Desktopdesktop-deep-linking-expense.mov |
|
Quick bump on the PR @cead22 |
|
✋ This PR was not deployed to staging yet because QA is ongoing. It will be automatically deployed to staging after the next production release. |
|
🚀 Deployed to staging by https://github.com/cead22 in version: 9.1.19-0 🚀
|
|
Might be related to deploy blocker #59130 ? |
|
🚀 Deployed to production by https://github.com/cristipaval in version: 9.1.19-5 🚀
|
| : transaction?.reportID === reportID; | ||
|
|
||
| // Exit if the transaction already exists and is associated with the current report | ||
| if (transaction?.transactionID && (!transaction?.isFromGlobalCreate || !isEmptyObject(transaction?.participants)) && isCurrentReportID) { |
There was a problem hiding this comment.
Coming from #59567, this caused an issue where the send invoice flow turns into a create expense instead. For invoices, isCurrentReportID will be (incorrectly) false because we don't set the first participant of an invoice flow if the participant is not an invoice room.
Explanation of Change
Fixed Issues
$ #56752
PROPOSAL: #56752 (comment)
Tests
Precondition: On Web or mWeb, submit an expense but stop at the Confirm Details page, copy and send the URL to a chat.
Offline tests
Same as tests
QA Steps
// TODO: These must be filled out, or the issue title must include "[No QA]."
Same as tests
PR Author Checklist
### Fixed Issuessection aboveTestssectionOffline stepssectionQA stepssectiontoggleReportand notonIconClick)src/languages/*files and using the translation methodSTYLE.md) were followedAvatar, I verified the components usingAvatarare working as expected)StyleUtils.getBackgroundAndBorderStyle(theme.componentBG))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
Android: Native
android.mov
Android: mWeb Chrome
android-mweb.mov
iOS: Native
ios-mweb.mov
iOS: mWeb Safari
ios-mweb.mov
MacOS: Chrome / Safari
web.mov
MacOS: Desktop
desktop.mov