Add Track expense follow up questions as rows in details view of a Tracked expense#51951
Add Track expense follow up questions as rows in details view of a Tracked expense#51951thienlnam merged 7 commits intoExpensify:mainfrom
Conversation
|
@aimane-chnaif 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] |
src/pages/ReportDetailsPage.tsx
Outdated
| const whisperAction = ReportActionsUtils.getTrackExpenseActionableWhisper(iouTransactionID, moneyRequestReport?.reportID ?? '0'); | ||
| const actionableWhisperReportActionID = whisperAction?.reportActionID ?? '0'; |
There was a problem hiding this comment.
I think we can define these 2 variables inside if (isTrackExpenseReport) condition below https://github.com/Expensify/App/pull/51951/files#diff-409b0e2fb439856e9897b808014031ce244a427d116ed30f37a2e0117599adc4R380 for optimization.
Reviewer Checklist
Screenshots/VideosAndroid: Nativeandroid.mp4Android: mWeb Chromemchrome.mp4iOS: Nativeios.moviOS: mWeb SafariMacOS: Chrome / Safariweb.movMacOS: Desktopdesktop.mov |
|
@aimane-chnaif Can you explain please why you accept him using my code from my proposal ?, since I proposed first using this solution cc: @thienlnam |
|
@NJ-2020 No need to provide full code diff in proposal stage, which can be same as final code from assigned contributor. @twilight2294 you exactly used @NJ-2020's code, right? If so, we can split bounty. |
|
@aimane-chnaif I cannot access those slack links And also I proposed the first solution using |
@aimane-chnaif I agree with this, we also have this in our contributor guidelines:
@thienlnam please merge this PR when you find time |
|
✋ 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/thienlnam in version: 9.0.59-0 🚀
|
|
🚀 Deployed to production by https://github.com/francoisl in version: 9.0.59-3 🚀
|
| }); | ||
| } | ||
|
|
||
| if (isTrackExpenseReport) { |
There was a problem hiding this comment.
This check caused the following issue:
because it didn't account for !isDeletedParentAction, which was fixed in PR #52786.
There was a problem hiding this comment.
Adding this exposed #52239. More thorough testing on mobile might have resulted in a fix.
| const whisperAction = ReportActionsUtils.getTrackExpenseActionableWhisper(iouTransactionID, moneyRequestReport?.reportID ?? '0'); | ||
| const actionableWhisperReportActionID = whisperAction?.reportActionID ?? '0'; | ||
| items.push({ | ||
| key: CONST.REPORT_DETAILS_MENU_ITEM.SETTINGS, |
There was a problem hiding this comment.
Each item should have a unique key to avoid such bug.
More info:
#57531 (comment)
Explanation of Change
Add the track expense options into the details view of a tracked expense. We currently use the details view of an expense to surface other actions like Delete or Download, so this is a natural place to include the other missing track options. This will then allow users to go back to their tracked expenses and easily send them or share them when they wish
Fixed Issues
$ #51358
PROPOSAL: #51358 (comment)
Tests
Verify that you see the 3 options :
Submit it to someone,Categorize it,Share it with my accountantSubmit it to someone, submit the expense to someone.Verify that you are able to submit the expense
Offline tests
N/A
QA Steps
Verify that you see the 3 options :
Submit it to someone,Categorize it,Share it with my accountantSubmit it to someone, submit the expense to someone.Verify that you are able to submit the expense
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
Screen.Recording.2024-11-04.at.6.31.44.PM.mov
Android: mWeb Chrome
Screen.Recording.2024-11-04.at.6.40.06.PM.mov
iOS: Native
Screen.Recording.2024-11-04.at.7.05.10.PM.mov
iOS: mWeb Safari
Screen.Recording.2024-11-04.at.6.37.49.PM.mov
MacOS: Chrome / Safari
Screen.Recording.2024-11-04.at.6.20.51.PM.mov
MacOS: Desktop
Screen.Recording.2024-11-04.at.6.29.54.PM.mov