Fix submit button when there is only non-reimbursable expenses#55610
Conversation
|
@ishpaul777 Can you start testing this PR please? Please test the scanning / fail receipt cases in this PR. |
|
🚧 @trjExpensify has triggered a test build. You can view the workflow run here. |
|
🧪🧪 Use the links below to test this adhoc build on Android, iOS, Desktop, and Web. Happy testing! 🧪🧪 |
|
on it today! |
ishpaul777
left a comment
There was a problem hiding this comment.
Seems to work well for all case mentioned 👍
Have a one expense report and the only expense is a pending ECard transition, we shouldn’t show the Submit button
I am not sure how to test this does this requires ECard setup? can you provide steps?
|
we have conflicts! @shubham1206agra |
|
BUMP! @shubham1206agra |
|
@ishpaul777 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] |
Reviewer Checklist
Screenshots/VideosAndroid: NativeScreen.Recording.2025-01-29.at.8.04.14.PM.movScreen.Recording.2025-01-29.at.8.07.30.PM.movAndroid: mWeb ChromeScreen.Recording.2025-01-29.at.8.15.59.PM.moviOS: NativeScreen.Recording.2025-01-29.at.7.52.41.PM.movScreen.Recording.2025-01-29.at.8.04.14.PM.moviOS: mWeb SafariScreen.Recording.2025-01-29.at.7.57.04.PM.movScreen.Recording.2025-01-29.at.7.54.56.PM.movMacOS: Chrome / SafariScreen.Recording.2025-01-29.at.6.26.13.PM.movScreen.Recording.2025-01-29.at.7.33.02.PM.movMacOS: DesktopScreen.Recording.2025-01-29.at.8.35.44.PM.mov |
|
will finish this one tmrw |
this test seems to be failing now before it was working Screen.Recording.2025-01-29.at.6.51.56.PM.mov |
|
@ishpaul777 You may have uploaded the wrong video. Can you please recheck? |
|
my bad! corrected it |
|
@ishpaul777 Let me take a look into this. Since no logic changed. |
|
@ishpaul777 Fixed |
|
✋ 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/lakchote in version: 9.0.92-0 🚀
|
|
@ishpaul777 all the steps are passed except the below one. We can't have a Ecard transaction.
|
|
🚀 Deployed to production by https://github.com/yuwenmemon in version: 9.0.92-6 🚀
|
| reimbursableSpend !== 0 && | ||
| !hasOnlyPendingCardOrScanFailTransactions && | ||
| !hasAllPendingRTERViolations && | ||
| !hasBrokenConnectionViolation && |
There was a problem hiding this comment.
coming from #56044, there was a regression, we should have added a transactions.length > 0 here
Explanation of Change
Fixed Issues
$ #55086
PROPOSAL: #55086 (comment)
Tests
Additional cases
Have a one expense report and the only expense is a pending ECard transition, we shouldn’t show the
SubmitbuttonHave a one expense report and the only expense is a scanning receipt, we shouldn’t show the
SubmitbuttonHave a batch/multi-expense report and all the expenses are scanning/pending, we shouldn’t show the
SubmitbuttonHave a batch/multi-expexpense report and only some of the expenses are scanning/pending should show the
SubmitbuttonVerify that no errors appear in the JS console
Offline tests
Same as Tests
QA Steps
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: mWeb Chrome
iOS: Native
iOS: mWeb Safari
MacOS: Chrome / Safari
MacOS: Desktop