|
|
|
|
@ -38,6 +38,7 @@ import { GfTransferBalanceDialogComponent } from './transfer-balance/transfer-ba
|
|
|
|
|
})
|
|
|
|
|
export class GfAccountsPageComponent implements OnDestroy, OnInit {
|
|
|
|
|
public accounts: AccountModel[];
|
|
|
|
|
public activitiesCount = 0;
|
|
|
|
|
public deviceType: string;
|
|
|
|
|
public hasImpersonationId: boolean;
|
|
|
|
|
public hasPermissionToCreateAccount: boolean;
|
|
|
|
|
@ -45,7 +46,6 @@ export class GfAccountsPageComponent implements OnDestroy, OnInit {
|
|
|
|
|
public routeQueryParams: Subscription;
|
|
|
|
|
public totalBalanceInBaseCurrency = 0;
|
|
|
|
|
public totalValueInBaseCurrency = 0;
|
|
|
|
|
public transactionCount = 0;
|
|
|
|
|
public user: User;
|
|
|
|
|
|
|
|
|
|
private unsubscribeSubject = new Subject<void>();
|
|
|
|
|
@ -128,14 +128,14 @@ export class GfAccountsPageComponent implements OnDestroy, OnInit {
|
|
|
|
|
.subscribe(
|
|
|
|
|
({
|
|
|
|
|
accounts,
|
|
|
|
|
activitiesCount,
|
|
|
|
|
totalBalanceInBaseCurrency,
|
|
|
|
|
totalValueInBaseCurrency,
|
|
|
|
|
transactionCount
|
|
|
|
|
totalValueInBaseCurrency
|
|
|
|
|
}) => {
|
|
|
|
|
this.accounts = accounts;
|
|
|
|
|
this.activitiesCount = activitiesCount;
|
|
|
|
|
this.totalBalanceInBaseCurrency = totalBalanceInBaseCurrency;
|
|
|
|
|
this.totalValueInBaseCurrency = totalValueInBaseCurrency;
|
|
|
|
|
this.transactionCount = transactionCount;
|
|
|
|
|
|
|
|
|
|
if (this.accounts?.length <= 0) {
|
|
|
|
|
this.router.navigate([], { queryParams: { createDialog: true } });
|
|
|
|
|
@ -358,8 +358,8 @@ export class GfAccountsPageComponent implements OnDestroy, OnInit {
|
|
|
|
|
|
|
|
|
|
private reset() {
|
|
|
|
|
this.accounts = undefined;
|
|
|
|
|
this.activitiesCount = 0;
|
|
|
|
|
this.totalBalanceInBaseCurrency = 0;
|
|
|
|
|
this.totalValueInBaseCurrency = 0;
|
|
|
|
|
this.transactionCount = 0;
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|