App: [HOLD for payment 2024-02-26] [$500] [ECARD TRANSACTIONS] Header in expense view shows `$%amount% request` instead of `$%amount% for %merchant%`

If you haven’t already, check out our contributing guidelines for onboarding and email contributors@expensify.com to request to join our Slack channel!


Issue reported by: @kevinksullivan Slack conversation: https://expensify.slack.com/archives/C05DWUDHVK7/p1705358211614989

Action Performed:

  1. Create a free workspace and set it as your default
  2. Incur a charge on an Expensify Card
  3. Tap into the report

Expected Result:

The report title should use the format $%amount% for %merchant%

Actual Result:

The report title shows $%amount% request

image

Upwork Automation - Do Not Edit
  • Upwork Job URL: https://www.upwork.com/jobs/~0122f6862da1ad40a2
  • Upwork Job ID: 1748127879346397184
  • Last Price Increase: 2024-02-01
  • Automatic offers:
    • fedirjh | Reviewer | 28144607
    • neonbhai | Contributor | 28144608

About this issue

  • Original URL
  • State: closed
  • Created 5 months ago
  • Comments: 41 (24 by maintainers)

Most upvoted comments

BugZero Checklist:

  • Link to the PR: N/A It is more of a feature request than a bug.
  • Link to comment: N/A
  • Link to discussion: N/A
  • Determine if we should create a regression test for this bug: Yes

Regression Test Proposal

1. Open chat with any user
2. Click on FAB -> Request Money
3. Enter an amount
4. Leave Merchant and Description empty, then create Request
5. Go to the Request View
6. Verify Header as the title "{amount} request"
7. Add a description to the request
8. Verify the header title changes to "{amount} for {description}"
9. Add a merchant to the title
10. Verify the header title changes to "{amount} for {merchant}"
  • Do we agree 👍 or 👎

thanks @neonbhai !

I agree with this:

https://github.com/Expensify/App/issues/34627#issuecomment-1911317195

We should be falling back to the comment.

@fedirjh hi, we now pass merchant for reimbursable transactions also. Latest main code was updated in this PR to always use merchant if available: https://github.com/Expensify/App/blob/a1fe671e94f69a694e2847a6b74685270149e991/src/libs/ReportUtils.ts#L2240

So a check for the reimbursable state is now not needed.