Browse Source

Fix today's performance and chart calculation

pull/1333/head
Thomas 3 years ago
parent
commit
d51068d1e8
  1. 3
      apps/api/src/app/portfolio/portfolio-calculator.ts

3
apps/api/src/app/portfolio/portfolio-calculator.ts

@ -16,6 +16,7 @@ import {
isBefore, isBefore,
isSameMonth, isSameMonth,
isSameYear, isSameYear,
isToday,
max, max,
min, min,
set set
@ -187,7 +188,9 @@ export class PortfolioCalculator {
day = addDays(day, step); day = addDays(day, step);
} }
if (!isToday(last(dates))) {
dates.push(resetHours(end)); dates.push(resetHours(end));
}
for (const item of transactionPointsBeforeEndDate[firstIndex - 1].items) { for (const item of transactionPointsBeforeEndDate[firstIndex - 1].items) {
dataGatheringItems.push({ dataGatheringItems.push({

Loading…
Cancel
Save