Browse Source

Refactor:interest to interestInBaseCurrency in portfolio summary interface

pull/5763/head
Dibyendu Sahoo 3 weeks ago
parent
commit
4eaa905f4e
  1. 2
      apps/api/src/app/portfolio/portfolio.controller.ts
  2. 2
      apps/api/src/app/portfolio/portfolio.service.ts
  3. 4
      apps/api/src/helper/object.helper.spec.ts
  4. 2
      apps/client/src/app/components/portfolio-summary/portfolio-summary.component.html
  5. 2
      libs/common/src/lib/interfaces/portfolio-summary.interface.ts

2
apps/api/src/app/portfolio/portfolio.controller.ts

@ -197,7 +197,7 @@ export class PortfolioController {
'filteredValueInBaseCurrency', 'filteredValueInBaseCurrency',
'grossPerformance', 'grossPerformance',
'grossPerformanceWithCurrencyEffect', 'grossPerformanceWithCurrencyEffect',
'interest', 'interestInBaseCurrency',
'items', 'items',
'liabilities', 'liabilities',
'netPerformance', 'netPerformance',

2
apps/api/src/app/portfolio/portfolio.service.ts

@ -2105,7 +2105,7 @@ export class PortfolioService {
) )
.plus(fees) .plus(fees)
.toNumber(), .toNumber(),
interest: interest.toNumber(), interestInBaseCurrency: interest.toNumber(),
liabilitiesInBaseCurrency: liabilities.toNumber(), liabilitiesInBaseCurrency: liabilities.toNumber(),
totalInvestment: totalInvestment.toNumber(), totalInvestment: totalInvestment.toNumber(),
totalValueInBaseCurrency: netWorth totalValueInBaseCurrency: netWorth

4
apps/api/src/helper/object.helper.spec.ts

@ -1536,7 +1536,7 @@ describe('redactAttributes', () => {
fireWealth: null, fireWealth: null,
grossPerformance: null, grossPerformance: null,
grossPerformanceWithCurrencyEffect: null, grossPerformanceWithCurrencyEffect: null,
interest: null, interestInBaseCurrency: null,
items: null, items: null,
liabilities: null, liabilities: null,
totalInvestment: null, totalInvestment: null,
@ -3039,7 +3039,7 @@ describe('redactAttributes', () => {
fireWealth: null, fireWealth: null,
grossPerformance: null, grossPerformance: null,
grossPerformanceWithCurrencyEffect: null, grossPerformanceWithCurrencyEffect: null,
interest: null, interestInBaseCurrency: null,
items: null, items: null,
liabilities: null, liabilities: null,
totalInvestment: null, totalInvestment: null,

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

@ -302,7 +302,7 @@
[isCurrency]="true" [isCurrency]="true"
[locale]="locale" [locale]="locale"
[unit]="baseCurrency" [unit]="baseCurrency"
[value]="isLoading ? undefined : summary?.interest" [value]="isLoading ? undefined : summary?.interestInBaseCurrency"
/> />
</div> </div>
</div> </div>

2
libs/common/src/lib/interfaces/portfolio-summary.interface.ts

@ -20,7 +20,7 @@ export interface PortfolioSummary extends PortfolioPerformance {
fireWealth: FireWealth; fireWealth: FireWealth;
grossPerformance: number; grossPerformance: number;
grossPerformanceWithCurrencyEffect: number; grossPerformanceWithCurrencyEffect: number;
interest: number; interestInBaseCurrency: number;
liabilitiesInBaseCurrency: number; liabilitiesInBaseCurrency: number;
totalBuy: number; totalBuy: number;
totalSell: number; totalSell: number;

Loading…
Cancel
Save