Browse Source
Feature/add quantity to holdings table of account detail dialog (#5379)
* Add quantity column
* Update changelog
pull/1946/merge
Thomas Kaul
3 days ago
committed by
GitHub
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
5 changed files with
32 additions and
0 deletions
-
CHANGELOG.md
-
apps/client/src/app/components/home-holdings/home-holdings.html
-
apps/client/src/app/pages/public/public-page.html
-
libs/ui/src/lib/holdings-table/holdings-table.component.html
-
libs/ui/src/lib/holdings-table/holdings-table.component.ts
|
|
@ -11,6 +11,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 |
|
|
|
|
|
|
|
- Included accounts in the search results of the assistant |
|
|
|
- Included the data source in the asset profile search results of the assistant |
|
|
|
- Added the quantity column to the holdings table of the account detail dialog |
|
|
|
|
|
|
|
### Changed |
|
|
|
|
|
|
|
|
|
@ -48,6 +48,7 @@ |
|
|
|
<gf-holdings-table |
|
|
|
[baseCurrency]="user?.settings?.baseCurrency" |
|
|
|
[deviceType]="deviceType" |
|
|
|
[hasPermissionToShowQuantities]="false" |
|
|
|
[holdings]="holdings" |
|
|
|
[locale]="user?.settings?.locale" |
|
|
|
(holdingClicked)="onHoldingClicked($event)" |
|
|
|
|
|
@ -201,6 +201,7 @@ |
|
|
|
[data]="holdings" |
|
|
|
[deviceType]="deviceType" |
|
|
|
[hasPermissionToOpenDetails]="false" |
|
|
|
[hasPermissionToShowQuantities]="false" |
|
|
|
[hasPermissionToShowValues]="false" |
|
|
|
[pageSize]="7" |
|
|
|
/> |
|
|
|
|
|
@ -64,6 +64,30 @@ |
|
|
|
</td> |
|
|
|
</ng-container> |
|
|
|
|
|
|
|
<ng-container matColumnDef="quantity"> |
|
|
|
<th |
|
|
|
*matHeaderCellDef |
|
|
|
class="d-none d-lg-table-cell justify-content-end px-1" |
|
|
|
mat-header-cell |
|
|
|
mat-sort-header |
|
|
|
> |
|
|
|
<ng-container i18n>Quantity</ng-container> |
|
|
|
</th> |
|
|
|
<td |
|
|
|
*matCellDef="let element" |
|
|
|
class="d-none d-lg-table-cell px-1" |
|
|
|
mat-cell |
|
|
|
> |
|
|
|
<div class="d-flex justify-content-end"> |
|
|
|
<gf-value |
|
|
|
[isCurrency]="true" |
|
|
|
[locale]="locale" |
|
|
|
[value]="isLoading ? undefined : element.quantity" |
|
|
|
/> |
|
|
|
</div> |
|
|
|
</td> |
|
|
|
</ng-container> |
|
|
|
|
|
|
|
<ng-container matColumnDef="valueInBaseCurrency"> |
|
|
|
<th |
|
|
|
*matHeaderCellDef |
|
|
|
|
|
@ -52,6 +52,7 @@ export class GfHoldingsTableComponent implements OnChanges, OnDestroy { |
|
|
|
@Input() baseCurrency: string; |
|
|
|
@Input() deviceType: string; |
|
|
|
@Input() hasPermissionToOpenDetails = true; |
|
|
|
@Input() hasPermissionToShowQuantities = true; |
|
|
|
@Input() hasPermissionToShowValues = true; |
|
|
|
@Input() holdings: PortfolioPosition[]; |
|
|
|
@Input() locale = getLocale(); |
|
|
@ -73,6 +74,10 @@ export class GfHoldingsTableComponent implements OnChanges, OnDestroy { |
|
|
|
public ngOnChanges() { |
|
|
|
this.displayedColumns = ['icon', 'nameWithSymbol', 'dateOfFirstActivity']; |
|
|
|
|
|
|
|
if (this.hasPermissionToShowQuantities) { |
|
|
|
this.displayedColumns.push('quantity'); |
|
|
|
} |
|
|
|
|
|
|
|
if (this.hasPermissionToShowValues) { |
|
|
|
this.displayedColumns.push('valueInBaseCurrency'); |
|
|
|
} |
|
|
|