App
App copied to clipboard
[HOLD for payment 2024-03-29] [LOW] [Splits] [$500] IOU - IOU description can't be seen on the LHN reports
If you haven’t already, check out our contributing guidelines for onboarding and email [email protected] to request to join our Slack channel!
Version Number: 1.4.3.2 Reproducible in staging?: y Reproducible in production?: y If this was caught during regression testing, add the test name, ID and link from TestRail: Email or phone of affected tester (no customers): Logs: https://stackoverflow.com/c/expensify/questions/4856 Expensify/Expensify Issue URL: Issue reported by: Applause - Internal Team Slack conversation:
Action Performed:
- Navigate to https://staging.new.expensify.com/
- Start a manual IOU with the FAB button
- Split with members you didn't have contact before
- Add any description
- Finalise the split
Expected Result:
IOU description should be seen on the LHN reports.
Actual Result:
IOU description can't be seen on the LHN reports. It shows at the group chat.
Workaround:
Unknown
Platforms:
Which of our officially supported platforms is this issue occurring on?
- [x] Android: Native
- [x] Android: mWeb Chrome
- [x] iOS: Native
- [x] iOS: mWeb Safari
- [x] MacOS: Chrome / Safari
- [x] MacOS: Desktop
Screenshots/Videos
Add any screenshot/video evidence
https://github.com/Expensify/App/assets/93399543/4dae53a0-7e50-430c-aaf6-cb55c8d180c5

Upwork Automation - Do Not Edit
- Upwork Job URL: https://www.upwork.com/jobs/~01f2930f214fff4630
- Upwork Job ID: 1728156217838292992
- Last Price Increase: 2024-01-06
Issue Owner
Current Issue Owner: @tobyjsullivan
Job added to Upwork: https://www.upwork.com/jobs/~01f2930f214fff4630
Triggered auto assignment to @NicMendonca (Bug), see https://stackoverflow.com/c/expensify/questions/14418 for more details.
Bug0 Triage Checklist (Main S/O)
- [ ] This "bug" occurs on a supported platform (ensure
Platformsin OP are ✅) - [ ] This bug is not a duplicate report (check E/App issues and #expensify-bugs)
- If it is, comment with a link to the original report, close the issue and add any novel details to the original issue instead
- [ ] This bug is reproducible using the reproduction steps in the OP. S/O
- If the reproduction steps are clear and you're unable to reproduce the bug, check with the reporter and QA first, then close the issue.
- If the reproduction steps aren't clear and you determine the correct steps, please update the OP.
- [ ] This issue is filled out as thoroughly and clearly as possible
- Pay special attention to the title, results, platforms where the bug occurs, and if the bug happens on staging/production.
- [ ] I have reviewed and subscribed to the linked Slack conversation to ensure Slack/Github stay in sync
Triggered auto assignment to Contributor-plus team member for initial proposal review - @parasharrajat (External)
Proposal
Please re-state the problem that we are trying to solve in this issue.
The report name is incomplete when splitting a money request between people. It is expected that the report name will take the form ${payer} owes {amount} for {description}; however, the description is currently excluded.
What is the root cause of that problem?
The translation used in getReportPreviewMessage (ReportUtils.js) does not include a comment part.
What changes do you think we should make in order to solve the problem?
Add a new translation, iou.payerOwesAmountFor of the form ({payer, amount, comment}: PayerOwesAmountForParams) => `${payer} owes ${amount} for ${comment}` and provide the comment from the linked transaction.
What alternative solutions did you explore? (Optional)
Note: the original report also highlighted issues with "requested {amount}" reports. However, these seem to have been removed with https://github.com/Expensify/App/pull/31860
Proposal
Please re-state the problem that we are trying to solve in this issue.
After splitting with members who have not contact before, IOU description should be seen on the LHN reports, and report name should be formatted as ${payer} owes ${amount} for ${comment}, but now it is formatted as ${payer} owes ${amount}.
What is the root cause of that problem?
The translation iou.payerOwesAmount don't include the part of comment, which is used as report name.
What changes do you think we should make in order to solve the problem?
- Insert a new optional property called
commentinPayerOwesAmountParams:
type PayerOwesAmountParams = {payer: string; amount: number; comment?: string};
- Update the translation
iou.payerOwesAmountto
({payer, amount, comment}: PayerOwesAmountParams) => `${payer} owes ${amount}${comment ? ` for ${comment}` : ''}`
- Export a new function for getting description from report action:
function getCommentOfMoneyRequest(reportAction: OnyxEntry<ReportAction>): string | void {
return reportAction?.actionName === CONST.REPORT.ACTIONS.TYPE.IOU ? reportAction?.originalMessage?.comment : undefined
}
- Use
getCommentOfMoneyRequestingetReportPreviewMessageof ReportUtils.js to get description, and put it in parameters ofiou.payerOwesAmount:
const comment = getCommentOfMoneyRequest(reportAction);
return Localize.translateLocal(containsNonReimbursable ? 'iou.payerSpentAmount' : 'iou.payerOwesAmount', {payer: payerName, amount: formattedAmount, comment});
What alternative solutions did you explore? (Optional)
Reminder: Please use plain English, be brief and avoid jargon. Feel free to use images, charts or pseudo-code if necessary. Do not post large multi-line diffs or write walls of text. Do not create PRs unless you have been hired for this job.
📣 @a67586646! 📣 Hey, it seems we don’t have your contributor details yet! You'll only have to do this once, and this is how we'll hire you on Upwork. Please follow these steps:
- Make sure you've read and understood the contributing guidelines.
- Get the email address used to login to your Expensify account. If you don't already have an Expensify account, create one here. If you have multiple accounts (e.g. one for testing), please use your main account email.
- Get the link to your Upwork profile. It's necessary because we only pay via Upwork. You can access it by logging in, and then clicking on your name. It'll look like this. If you don't already have an account, sign up for one here.
- Copy the format below and paste it in a comment on this issue. Replace the placeholder text with your actual details.
Format:
Contributor details
Your Expensify account email: <REPLACE EMAIL HERE>
Upwork Profile Link: <REPLACE LINK HERE>
Contributor details Your Expensify account email: [email protected] Upwork Profile Link: https://www.upwork.com/freelancers/~011d63f7ce68a2aa54
✅ Contributor details stored successfully. Thank you for contributing to Expensify!
@parasharrajat proposals for you!
I don't think this is a bug. The expected of this issue is to display the description in LHN's subtitle of IOU report. But let's see this case when we request 2 times, the first request don't have description, the second request have a description. Currently, we are displaying total amount in LHN without description
Correct. I also think it is expected. The description was added to the split request and thus that report shows it. I need sometime to debug this.
Currently, the results are shown based on how it is coded. Now we need to determine if we want this change. @NicMendonca Can you please confirm if we want to make this change?
asked here - https://expensify.slack.com/archives/C01SKUP7QR0/p1701371462794629
📣 It's been a week! Do we have any satisfactory proposals yet? Do we need to adjust the bounty for this issue? 💸
@parasharrajat, @NicMendonca Eep! 4 days overdue now. Issues have feelings too...
Waiting on internal discussion.
@parasharrajat @NicMendonca this issue was created 2 weeks ago. Are we close to approving a proposal? If not, what's blocking us from getting this issue assigned? Don't hesitate to create a thread in #expensify-open-source to align faster in real time. Thanks!
@parasharrajat, @NicMendonca Uh oh! This issue is overdue by 2 days. Don't forget to update your issues!
Any update @NicMendonca
📣 It's been a week! Do we have any satisfactory proposals yet? Do we need to adjust the bounty for this issue? 💸
@parasharrajat, @NicMendonca Whoops! This issue is 2 days overdue. Let's get this updated quick!
bumped internal discussion again! https://expensify.slack.com/archives/C05RECHFBEW/p1701783220128649
internal feedback:
if there is a description, we should be showing it.
@NicMendonca You mean that we only show description if there is a money request? If we have many money requests with many descriptions as I detailed here, which description should we show in the subtitle of LHN? cc @parasharrajat
@parasharrajat @NicMendonca this issue is now 3 weeks old. There is one more week left before this issue breaks WAQ and will need to go internal. What needs to happen to get a PR in review this week? Please create a thread in #expensify-open-source to discuss. Thanks!
@parasharrajat, @NicMendonca Uh oh! This issue is overdue by 2 days. Don't forget to update your issues!
📣 It's been a week! Do we have any satisfactory proposals yet? Do we need to adjust the bounty for this issue? 💸
discussing here: https://expensify.slack.com/archives/C05RECHFBEW/p1702912365521069?thread_ts=1701783220.128649&cid=C05RECHFBEW