Browse Source

Bugfix/endless loading state of values (#7971)

* Fix value column of top holdings in Presenter View

* Fix projected sustainable retirement income for projected total amount of zero

* Fix emergency fund in portfolio summary for redacted values

* Update changelog
pull/7972/head^2
Thomas Kaul 1 week ago
committed by GitHub
parent
commit
720ad531a1
No known key found for this signature in database GPG Key ID: B5690EEEBB952194
  1. 6
      CHANGELOG.md
  2. 4
      apps/client/src/app/components/portfolio-summary/portfolio-summary.component.html
  3. 1
      apps/client/src/app/pages/portfolio/allocations/allocations-page.html
  4. 4
      apps/client/src/app/pages/portfolio/fire/fire-page.component.ts
  5. 15
      libs/ui/src/lib/top-holdings/top-holdings.component.ts

6
CHANGELOG.md

@ -16,6 +16,12 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
- Extended the emergency fund dialog in the portfolio summary to include the currency suffix - Extended the emergency fund dialog in the portfolio summary to include the currency suffix
- Migrated the client to the code generated by the new `prisma-client` generator of _Prisma_ - Migrated the client to the code generated by the new `prisma-client` generator of _Prisma_
### Fixed
- Fixed the value column of the top holdings on the allocations page in the _Presenter View_
- Fixed the projected sustainable retirement income on the _FIRE_ page for a projected total amount of zero (experimental)
- Fixed the emergency fund in the portfolio summary for redacted values
## 3.75.0 - 2026-09-28 ## 3.75.0 - 2026-09-28
### Changed ### Changed

4
apps/client/src/app/components/portfolio-summary/portfolio-summary.component.html

@ -486,7 +486,9 @@
[locale]="locale" [locale]="locale"
[precision]="precision" [precision]="precision"
[unit]="displayedCurrency" [unit]="displayedCurrency"
[value]="summary?.emergencyFund?.total" [value]="
summary?.emergencyFund === null ? null : summary?.emergencyFund?.total
"
/> />
</div> </div>
</div> </div>

1
apps/client/src/app/pages/portfolio/allocations/allocations-page.html

@ -341,6 +341,7 @@
<mat-card-content> <mat-card-content>
<gf-top-holdings <gf-top-holdings
[baseCurrency]="user?.settings?.baseCurrency" [baseCurrency]="user?.settings?.baseCurrency"
[hasPermissionToShowValues]="!showValuesInPercentage()"
[locale]="user?.settings?.locale" [locale]="user?.settings?.locale"
[pageSize]="10" [pageSize]="10"
[topHoldings]="topHoldings" [topHoldings]="topHoldings"

4
apps/client/src/app/pages/portfolio/fire/fire-page.component.ts

@ -27,6 +27,7 @@ import { takeUntilDestroyed } from '@angular/core/rxjs-interop';
import { FormsModule, ReactiveFormsModule } from '@angular/forms'; import { FormsModule, ReactiveFormsModule } from '@angular/forms';
import { FormControl } from '@angular/forms'; import { FormControl } from '@angular/forms';
import { Big } from 'big.js'; import { Big } from 'big.js';
import { isFinite, isNumber } from 'lodash';
import { DeviceDetectorService } from 'ngx-device-detector'; import { DeviceDetectorService } from 'ngx-device-detector';
import { NgxSkeletonLoaderModule } from 'ngx-skeleton-loader'; import { NgxSkeletonLoaderModule } from 'ngx-skeleton-loader';
@ -256,7 +257,8 @@ export class GfFirePageComponent implements OnInit {
private calculateWithdrawalRatesProjected() { private calculateWithdrawalRatesProjected() {
if ( if (
this.fireWealth && this.fireWealth &&
this.projectedTotalAmount && isNumber(this.projectedTotalAmount) &&
isFinite(this.projectedTotalAmount) &&
this.user?.settings?.safeWithdrawalRate this.user?.settings?.safeWithdrawalRate
) { ) {
this.withdrawalRatePerYearProjected = new Big( this.withdrawalRatePerYearProjected = new Big(

15
libs/ui/src/lib/top-holdings/top-holdings.component.ts

@ -39,6 +39,7 @@ import { GfValueComponent } from '../value/value.component';
}) })
export class GfTopHoldingsComponent implements OnChanges { export class GfTopHoldingsComponent implements OnChanges {
@Input() baseCurrency: string; @Input() baseCurrency: string;
@Input() hasPermissionToShowValues = true;
@Input() locale = getLocale(); @Input() locale = getLocale();
@Input() pageSize = Number.MAX_SAFE_INTEGER; @Input() pageSize = Number.MAX_SAFE_INTEGER;
@Input() topHoldings: HoldingWithParents[]; @Input() topHoldings: HoldingWithParents[];
@ -48,14 +49,18 @@ export class GfTopHoldingsComponent implements OnChanges {
@ViewChild(MatPaginator) paginator: MatPaginator; @ViewChild(MatPaginator) paginator: MatPaginator;
public dataSource = new MatTableDataSource<HoldingWithParents>(); public dataSource = new MatTableDataSource<HoldingWithParents>();
public displayedColumns: string[] = [ public displayedColumns: string[] = [];
'name',
'valueInBaseCurrency',
'allocationInPercentage'
];
public isLoading = true; public isLoading = true;
public ngOnChanges() { public ngOnChanges() {
this.displayedColumns = ['name'];
if (this.hasPermissionToShowValues) {
this.displayedColumns.push('valueInBaseCurrency');
}
this.displayedColumns.push('allocationInPercentage');
this.isLoading = true; this.isLoading = true;
this.dataSource = new MatTableDataSource(this.topHoldings); this.dataSource = new MatTableDataSource(this.topHoldings);

Loading…
Cancel
Save