Browse Source

Migrate from details to portfolio holdings

pull/3123/head
Thomas Kaul 1 year ago
parent
commit
c7955f46d7
  1. 8
      apps/client/src/app/components/account-detail-dialog/account-detail-dialog.component.ts

8
apps/client/src/app/components/account-detail-dialog/account-detail-dialog.component.ts

@ -115,7 +115,7 @@ export class AccountDetailDialog implements OnDestroy, OnInit {
); );
this.dataService this.dataService
.fetchPortfolioDetails({ .fetchPortfolioHoldings({
filters: [ filters: [
{ {
type: 'ACCOUNT', type: 'ACCOUNT',
@ -125,11 +125,7 @@ export class AccountDetailDialog implements OnDestroy, OnInit {
}) })
.pipe(takeUntil(this.unsubscribeSubject)) .pipe(takeUntil(this.unsubscribeSubject))
.subscribe(({ holdings }) => { .subscribe(({ holdings }) => {
this.holdings = []; this.holdings = holdings;
for (const [symbol, holding] of Object.entries(holdings)) {
this.holdings.push(holding);
}
this.changeDetectorRef.markForCheck(); this.changeDetectorRef.markForCheck();
}); });

Loading…
Cancel
Save