pull/239/head
Thomas 3 years ago
parent 9e4a49d811
commit c47578bd3e

@ -79,13 +79,13 @@ export class CurrentRateService {
const result = []; const result = [];
for (const symbol of symbols) { for (const symbol of symbols) {
result.push({ result.push({
symbol,
date: today, date: today,
marketPrice: this.exchangeRateDataService.toCurrency( marketPrice: this.exchangeRateDataService.toCurrency(
dataResultProvider?.[symbol]?.marketPrice ?? 0, dataResultProvider?.[symbol]?.marketPrice ?? 0,
dataResultProvider?.[symbol]?.currency, dataResultProvider?.[symbol]?.currency,
userCurrency userCurrency
), )
symbol: symbol
}); });
} }
return result; return result;

@ -300,8 +300,8 @@ export class PortfolioCalculator {
return { return {
...overall, ...overall,
hasErrors: hasErrors || overall.hasErrors, positions,
positions hasErrors: hasErrors || overall.hasErrors
}; };
} }
@ -426,11 +426,11 @@ export class PortfolioCalculator {
} }
return { return {
currentValue, currentValue,
totalInvestment,
grossPerformance, grossPerformance,
hasErrors,
totalInvestment,
grossPerformancePercentage: grossPerformancePercentage:
grossPerformancePercentage.div(completeInitialValue), grossPerformancePercentage.div(completeInitialValue)
hasErrors
}; };
} }

Loading…
Cancel
Save