Browse Source

Merge branch 'main' into Task/validate-key-admin-settings

pull/7247/head
Shaik Aftab 1 week ago
committed by GitHub
parent
commit
4d690aca2d
No known key found for this signature in database GPG Key ID: B5690EEEBB952194
  1. 1
      CHANGELOG.md
  2. 4
      apps/api/src/app/portfolio/calculator/roai/portfolio-calculator-cash.spec.ts
  3. 9
      apps/client/src/app/pages/portfolio/fire/fire-page.component.ts

1
CHANGELOG.md

@ -10,6 +10,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
### Changed ### Changed
- Hardened the endpoint to update a property of the admin control panel by validating the `key` path parameter - Hardened the endpoint to update a property of the admin control panel by validating the `key` path parameter
- Set the change detection strategy to `OnPush` in the _FIRE_ page
## 3.21.0 - 2026-07-05 ## 3.21.0 - 2026-07-05

4
apps/api/src/app/portfolio/calculator/roai/portfolio-calculator-cash.spec.ts

@ -148,15 +148,15 @@ describe('PortfolioCalculator', () => {
balances: [ balances: [
{ {
accountId, accountId,
id: randomUUID(),
date: parseDate('2023-12-31'), date: parseDate('2023-12-31'),
id: randomUUID(),
value: 1000, value: 1000,
valueInBaseCurrency: 850 valueInBaseCurrency: 850
}, },
{ {
accountId, accountId,
id: randomUUID(),
date: parseDate('2024-12-31'), date: parseDate('2024-12-31'),
id: randomUUID(),
value: 2000, value: 2000,
valueInBaseCurrency: 1800 valueInBaseCurrency: 1800
} }

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

@ -14,6 +14,7 @@ import { GfValueComponent } from '@ghostfolio/ui/value';
import { CommonModule } from '@angular/common'; import { CommonModule } from '@angular/common';
import { import {
ChangeDetectionStrategy,
ChangeDetectorRef, ChangeDetectorRef,
Component, Component,
computed, computed,
@ -29,6 +30,7 @@ import { DeviceDetectorService } from 'ngx-device-detector';
import { NgxSkeletonLoaderModule } from 'ngx-skeleton-loader'; import { NgxSkeletonLoaderModule } from 'ngx-skeleton-loader';
@Component({ @Component({
changeDetection: ChangeDetectionStrategy.OnPush,
imports: [ imports: [
CommonModule, CommonModule,
FormsModule, FormsModule,
@ -89,6 +91,7 @@ export class GfFirePageComponent implements OnInit {
: 0 : 0
} }
}; };
if (this.user.subscription?.type === SubscriptionType.Basic) { if (this.user.subscription?.type === SubscriptionType.Basic) {
this.fireWealth = { this.fireWealth = {
today: { today: {
@ -107,6 +110,8 @@ export class GfFirePageComponent implements OnInit {
.pipe(takeUntilDestroyed(this.destroyRef)) .pipe(takeUntilDestroyed(this.destroyRef))
.subscribe((impersonationId) => { .subscribe((impersonationId) => {
this.hasImpersonationId = !!impersonationId; this.hasImpersonationId = !!impersonationId;
this.changeDetectorRef.markForCheck();
}); });
this.safeWithdrawalRateControl.valueChanges this.safeWithdrawalRateControl.valueChanges
@ -135,9 +140,9 @@ export class GfFirePageComponent implements OnInit {
); );
this.calculateWithdrawalRates(); this.calculateWithdrawalRates();
this.changeDetectorRef.markForCheck();
} }
this.changeDetectorRef.markForCheck();
}); });
} }

Loading…
Cancel
Save