Expensify / App

Welcome to New Expensify: a complete re-imagination of financial collaboration, centered around chat. Help us build the next generation of Expensify by sharing feedback and contributing to the code.
https://new.expensify.com
MIT License
3.57k stars 2.91k forks source link

Distance - Default rate is not in USD when workspace is created from "Pay with Expensify" #52927

Open IuliiaHerets opened 12 hours ago

IuliiaHerets commented 12 hours ago

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


Version Number: 9.0.65-3 Reproducible in staging?: Y Reproducible in production?: Y If this was caught on HybridApp, is this reproducible on New Expensify Standalone?: Y If this was caught during regression testing, add the test name, ID and link from TestRail: https://expensify.testrail.io/index.php?/tests/view/5250110 Email or phone of affected tester (no customers): applausetester+kh0811007s2@applause.expensifail.com Issue reported by: Applause Internal Team

Action Performed:

Precondition:

  1. Go to staging.new.expensify.com
  2. Go to FAB > Submit expense > Distance.
  3. Enter waypoints > Next.
  4. Enter email of a new account (does not have Expensify account).
  5. Submit the expense.
  6. Log in as the expense receiver.
  7. Go to main chat with the expense submitter.
  8. Click Pay with Expensify > Business bank account.
  9. Close the bank account set up RHP.
  10. Go to transaction thread.
  11. Note that the distance rate is in USD.
  12. Go to workspace settings > More features.
  13. Enable Distance rates.
  14. Note that the default distance rate is in local currency (MYR in this case).
  15. Add a new distance rate,
  16. Note that the new distance rate is in USD.

Expected Result:

In Step 14, the default distance rate should be in USD because the default workspace currency is USD.

Actual Result:

In Step 14, the default distance rate is in local currency when the default workspace currency is USD. In Step 16, the new distance rate is in USD.

Workaround:

Unknown

Platforms:

Screenshots/Videos

https://github.com/user-attachments/assets/af61110a-4fcb-44bc-a1fe-13b8d1fe45da

View all open jobs on GitHub

melvin-bot[bot] commented 12 hours ago

Triggered auto assignment to @sakluger (Bug), see https://stackoverflow.com/c/expensify/questions/14418 for more details. Please add this bug to a GH project, as outlined in the SO.

jacobkim9881 commented 4 hours ago

The currency is created when requesting API : CreateWorkspaceFromIOUPayment. Requested currency was USD but responsed currency is foreign currency. I think there is a logic to change currency on BE API.

//Requested
{
    "customUnitRateID": "E1A6CCD5F313F",
    "name": "Default Rate",
    "rate": 67,
    "enabled": true,
    "currency": "USD"
}

//Responsed

{
    "currency": "KRW",
    "customUnitRateID": "E1A6CCD5F313F",
    "enabled": true,
    "name": "Default Rate",
    "rate": 67
}