-
Notifications
You must be signed in to change notification settings - Fork 2.9k
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
Track Expense flow #37282
Track Expense flow #37282
Conversation
@thienlnam I have completed preliminary flow. I want to HOLD this on #37165 as I want to pick some common components from there.Mainly for To section in Confirmation Step. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks, just a couple notes for far - it looks the track flow doesn't yet auto-select the self-DM as destination?
It does select. You need to set selfDMReportID in Account Onyx key. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Couple comments so far, also looks like we are failing some ts typechecks
src/pages/home/sidebar/SidebarScreen/FloatingActionButtonAndPopover.js
Outdated
Show resolved
Hide resolved
src/libs/ReportUtils.ts
Outdated
if (canUseTrackExpense && isPolicyExpenseChat(report) && report?.isOwnPolicyExpenseChat) { | ||
options = [...options, CONST.IOU.TYPE.TRACK_EXPENSE]; | ||
} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@thienlnam I am thinking of disabling the track expense in workspace temporarily. Will re-enable it in a follow up PR. This is basically for reason that the logic for deleting the request / updating the amount gets complicated, and this feature details in workspace is not flushed through completely. Since the plan was enable this feature to all users in near future, I think, delivering the workspace track expense incomplete may not have best outcome for users.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Sure that works, we can create another issue for this to get added into the workspace
@ishpaul777 Can you start doing preliminary tests here? We want to ship this PR by friday. |
Sure! Will start in 1-2 hours |
Just so you know i have already started testing, will spend some time testing for the flow before looking deep in code. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Awesome, thanks - there's a few things that will need BE updates. I'm planning on making issues so we can track those but it doesn't need to block this PR.
@shawnborton / @dubielzyk-expensify The beta takes an hour to kick in, are you able to see the option now? |
Still no. Are you able to check/add me to the beta in case I messed it up? |
Ah yeah that is currently known |
Merging so we can get this project back on track for the may release - please let us know if there are other design items that look off. We're keeping the beta on until we get these BE issues fixed |
@thienlnam looks like this was merged without a test passing. Please add a note explaining why this was done and remove the |
Tests were passing 😵 |
🚀 Deployed to staging by https://github.com/thienlnam in version: 1.4.56-0 🚀
|
🚀 Deployed to production by https://github.com/yuwenmemon in version: 1.4.56-8 🚀
|
Because |
@@ -71,11 +71,15 @@ function MoneyRequestHeader({session, parentReport, report, parentReportAction, | |||
const deleteTransaction = useCallback(() => { | |||
if (parentReportAction) { | |||
const iouTransactionID = parentReportAction.actionName === CONST.REPORT.ACTIONS.TYPE.IOU ? parentReportAction.originalMessage?.IOUTransactionID ?? '' : ''; | |||
if (ReportActionsUtils.isTrackExpenseAction(parentReportAction)) { | |||
IOU.deleteTrackExpense(parentReport?.reportID ?? '', iouTransactionID, parentReportAction, true); | |||
return; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
|
||
const transactionDetails = getTransactionDetails(linkedTransaction); | ||
const formattedAmount = CurrencyUtils.convertToDisplayString(transactionDetails?.amount ?? 0, transactionDetails?.currency ?? ''); | ||
return Localize.translateLocal('iou.trackedAmount', {formattedAmount, comment: transactionDetails?.comment ?? ''}); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
If merchant present comment should be merchant rather than transaction description #49993
Details
Fixed Issues
$ #36362
Tests
Test 1
Test 2
Test 3
Test 4
Test 5 (Delete Track Expense)
Offline tests
Same as Tests
QA Steps
Same as Tests.
PR Author Checklist
### Fixed Issues
section aboveTests
sectionOffline steps
sectionQA steps
sectiontoggleReport
and notonIconClick
)myBool && <MyComponent />
.src/languages/*
files and using the translation methodWaiting for Copy
label for a copy review on the original GH to get the correct copy.STYLE.md
) were followedAvatar
, I verified the components usingAvatar
are working as expected)StyleUtils.getBackgroundAndBorderStyle(theme.componentBG)
)Avatar
is modified, I verified thatAvatar
is working as expected in all cases)Design
label so the design team can review the changes.ScrollView
component to make it scrollable when more elements are added to the page.main
branch was merged into this PR after a review, I tested again and verified the outcome was still expected according to theTest
steps.Screenshots/Videos
Screenshots for Design Reference
Android: Native
Screen.Recording.2024-03-20.at.7.35.56.PM.mov
Android: mWeb Chrome
Screen.Recording.2024-03-20.at.6.31.25.PM.mov
iOS: Native
Screen.Recording.2024-03-20.at.7.19.00.PM.mov
iOS: mWeb Safari
Screen.Recording.2024-03-20.at.6.18.28.PM.mov
MacOS: Chrome / Safari
Screen.Recording.2024-03-20.at.5.44.15.PM.mp4
Screen.Recording.2024-03-20.at.5.46.49.PM.mp4
MacOS: Desktop
Screen.Recording.2024-03-20.at.7.11.40.PM.mov