Bug description
With Medusa v2.18.0 and featureFlags.view_configurations: true, the default configurable Orders table displays order totals as USD even when the store, region, and order all use TWD.
The underlying order data is correct. This appears to be a display-only issue in the Admin configurable table.
System information
- Medusa version: 2.18.0
@medusajs/dashboard: 2.18.0
- Node.js: 22.23.1
- Database: PostgreSQL on Railway
- Production OS: Linux container
- Browser: Chrome
Configuration
featureFlags: {
view_configurations: true,
}
The relevant data is equivalent to:
{
"store_currency": "twd",
"region_currency": "twd",
"order": {
"currency_code": "twd",
"total": 2040
}
}
Steps to reproduce
- Configure the store and a region to use TWD.
- Enable
featureFlags.view_configurations.
- Create an order in TWD.
- Open the Admin Orders page at
/app/orders using the default code-defined view.
- Keep
total visible and currency_code hidden, which are the default column visibility settings returned for the Orders view.
- Observe the currency shown for the total.
Expected behavior
The order total should be formatted using the order currency, for example NT$2,040 / TWD.
Actual behavior
The Orders table displays $2,040.00 USD.
Suspected root cause
The Orders columns endpoint marks total as visible by default and currency_code as hidden. The configurable table only requests the visible fields, so row.currency_code is absent when the total cell is rendered.
In v2.18.0, CurrencyRenderer then falls back to USD:
const CurrencyRenderer: CellRenderer = (value, row, _column, _t) => {
return <TotalCell currencyCode={row.currency_code || "USD"} total={value} />
}
Source: https://github.com/medusajs/medusa/blob/v2.18.0/packages/admin/dashboard/src/lib/table/cell-renderers.tsx#L445-L447
This means any non-USD order can be rendered as USD whenever currency_code is not included in the selected fields.
Suggested fix
When a currency-rendered field such as total is selected, automatically include its currency-code dependency in the query, even if that dependency is not a visible column. Alternatively, allow the column metadata to specify the currency source field and avoid a hard-coded USD fallback when the source field is missing.
Additional context
- The Admin Orders API returns the correct
currency_code: "twd" for the affected orders.
- The store and region both use TWD.
- The legacy/non-configurable Orders table includes the currency code and formats the same orders correctly.
- No customer or monetary data is corrupted; this is an Admin display issue.
- A public reproduction repository is not available, but the behavior is reproducible with the default configurable Orders view in v2.18.0.
Bug description
With Medusa v2.18.0 and
featureFlags.view_configurations: true, the default configurable Orders table displays order totals as USD even when the store, region, and order all use TWD.The underlying order data is correct. This appears to be a display-only issue in the Admin configurable table.
System information
@medusajs/dashboard: 2.18.0Configuration
The relevant data is equivalent to:
{ "store_currency": "twd", "region_currency": "twd", "order": { "currency_code": "twd", "total": 2040 } }Steps to reproduce
featureFlags.view_configurations./app/ordersusing the default code-defined view.totalvisible andcurrency_codehidden, which are the default column visibility settings returned for the Orders view.Expected behavior
The order total should be formatted using the order currency, for example
NT$2,040/ TWD.Actual behavior
The Orders table displays
$2,040.00 USD.Suspected root cause
The Orders columns endpoint marks
totalas visible by default andcurrency_codeas hidden. The configurable table only requests the visible fields, sorow.currency_codeis absent when the total cell is rendered.In v2.18.0,
CurrencyRendererthen falls back to USD:Source: https://github.com/medusajs/medusa/blob/v2.18.0/packages/admin/dashboard/src/lib/table/cell-renderers.tsx#L445-L447
This means any non-USD order can be rendered as USD whenever
currency_codeis not included in the selected fields.Suggested fix
When a currency-rendered field such as
totalis selected, automatically include its currency-code dependency in the query, even if that dependency is not a visible column. Alternatively, allow the column metadata to specify the currency source field and avoid a hard-coded USD fallback when the source field is missing.Additional context
currency_code: "twd"for the affected orders.