display the currency name instead of the currency code when using the source account currency or destination account currency as the axis, category or series in insights explorer

This commit is contained in:
MaysWind
2026-03-18 00:11:55 +08:00
parent 9772d9ca62
commit 1a65bb9db6
@@ -245,6 +245,7 @@ const {
getMonthdayShortName,
getWeekdayLongName,
getQuarterName,
getCurrencyName,
formatDateTimeToShortDateTime,
formatDateTimeToShortDate,
formatDateTimeToGregorianLikeShortYear,
@@ -487,6 +488,10 @@ function getCategoriedDataDisplayName(info: CategoriedInfo | SeriesInfo): string
displayName = month ? getMonthLongName(month.name) : tt('Unknown');
} else if (dimession === TransactionExplorerDataDimension.DateTimeByQuarterOfYear.value) {
displayName = getQuarterName(parseInt(name));
} else if (dimession === TransactionExplorerDataDimension.SourceAccountCurrency.value || dimession === TransactionExplorerDataDimension.DestinationAccountCurrency.value) {
if (!needI18n) {
displayName = getCurrencyName(name);
}
}
if (dimession === TransactionExplorerDataDimension.SourceAmount.value