Browse Source
Task/add asset profile to portfolio position interface (part 2) (#6500)
* Add currency to asset profile
pull/6502/head
Thomas Kaul
1 day ago
committed by
GitHub
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
3 changed files with
11 additions and
0 deletions
-
apps/api/src/app/portfolio/portfolio.service.ts
-
libs/common/src/lib/interfaces/portfolio-position.interface.ts
-
libs/ui/src/lib/mocks/holdings.ts
|
|
|
@ -628,6 +628,7 @@ export class PortfolioService { |
|
|
|
assetSubClass: assetProfile.assetSubClass, |
|
|
|
countries: assetProfile.countries, |
|
|
|
dataSource: assetProfile.dataSource, |
|
|
|
currency: assetProfile.currency, |
|
|
|
holdings: assetProfile.holdings.map( |
|
|
|
({ allocationInPercentage, name }) => { |
|
|
|
return { |
|
|
|
@ -1699,6 +1700,7 @@ export class PortfolioService { |
|
|
|
assetClass: AssetClass.LIQUIDITY, |
|
|
|
assetSubClass: AssetSubClass.CASH, |
|
|
|
assetProfile: { |
|
|
|
currency, |
|
|
|
assetClass: AssetClass.LIQUIDITY, |
|
|
|
assetSubClass: AssetSubClass.CASH, |
|
|
|
countries: [], |
|
|
|
|
|
|
|
@ -22,6 +22,7 @@ export interface PortfolioPosition { |
|
|
|
| 'assetClass' |
|
|
|
| 'assetSubClass' |
|
|
|
| 'countries' |
|
|
|
| 'currency' |
|
|
|
| 'dataSource' |
|
|
|
| 'holdings' |
|
|
|
| 'name' |
|
|
|
@ -42,6 +43,7 @@ export interface PortfolioPosition { |
|
|
|
/** @deprecated */ |
|
|
|
countries: Country[]; |
|
|
|
|
|
|
|
/** @deprecated */ |
|
|
|
currency: string; |
|
|
|
|
|
|
|
/** @deprecated */ |
|
|
|
|
|
|
|
@ -17,6 +17,7 @@ export const holdings: PortfolioPosition[] = [ |
|
|
|
weight: 1 |
|
|
|
} |
|
|
|
], |
|
|
|
currency: 'USD', |
|
|
|
dataSource: 'YAHOO', |
|
|
|
holdings: [], |
|
|
|
sectors: [ |
|
|
|
@ -81,6 +82,7 @@ export const holdings: PortfolioPosition[] = [ |
|
|
|
weight: 1 |
|
|
|
} |
|
|
|
], |
|
|
|
currency: 'EUR', |
|
|
|
dataSource: 'YAHOO', |
|
|
|
holdings: [], |
|
|
|
sectors: [ |
|
|
|
@ -145,6 +147,7 @@ export const holdings: PortfolioPosition[] = [ |
|
|
|
weight: 1 |
|
|
|
} |
|
|
|
], |
|
|
|
currency: 'USD', |
|
|
|
dataSource: 'YAHOO', |
|
|
|
holdings: [], |
|
|
|
sectors: [ |
|
|
|
@ -202,6 +205,7 @@ export const holdings: PortfolioPosition[] = [ |
|
|
|
assetClass: 'LIQUIDITY', |
|
|
|
assetSubClass: 'CASH', |
|
|
|
countries: [], |
|
|
|
currency: 'USD', |
|
|
|
dataSource: 'COINGECKO', |
|
|
|
holdings: [], |
|
|
|
sectors: [], |
|
|
|
@ -249,6 +253,7 @@ export const holdings: PortfolioPosition[] = [ |
|
|
|
weight: 1 |
|
|
|
} |
|
|
|
], |
|
|
|
currency: 'USD', |
|
|
|
dataSource: 'YAHOO', |
|
|
|
holdings: [], |
|
|
|
sectors: [ |
|
|
|
@ -313,6 +318,7 @@ export const holdings: PortfolioPosition[] = [ |
|
|
|
weight: 1 |
|
|
|
} |
|
|
|
], |
|
|
|
currency: 'USD', |
|
|
|
dataSource: 'YAHOO', |
|
|
|
holdings: [], |
|
|
|
sectors: [ |
|
|
|
@ -377,6 +383,7 @@ export const holdings: PortfolioPosition[] = [ |
|
|
|
weight: 1 |
|
|
|
} |
|
|
|
], |
|
|
|
currency: 'USD', |
|
|
|
dataSource: 'YAHOO', |
|
|
|
holdings: [], |
|
|
|
sectors: [ |
|
|
|
|