|
|
@ -66,7 +66,6 @@ import { GfValueComponent } from '../value'; |
|
|
export class GfAccountBalancesComponent implements OnChanges, OnInit { |
|
|
export class GfAccountBalancesComponent implements OnChanges, OnInit { |
|
|
@Input() accountBalances: AccountBalancesResponse['balances']; |
|
|
@Input() accountBalances: AccountBalancesResponse['balances']; |
|
|
@Input() accountCurrency: string; |
|
|
@Input() accountCurrency: string; |
|
|
@Input() accountId: string; |
|
|
|
|
|
|
|
|
|
|
|
@Output() accountBalanceCreated = new EventEmitter<CreateAccountBalanceDto>(); |
|
|
@Output() accountBalanceCreated = new EventEmitter<CreateAccountBalanceDto>(); |
|
|
@Output() accountBalanceDeleted = new EventEmitter<string>(); |
|
|
@Output() accountBalanceDeleted = new EventEmitter<string>(); |
|
|
@ -82,10 +81,10 @@ export class GfAccountBalancesComponent implements OnChanges, OnInit { |
|
|
AccountBalancesResponse['balances'][0] |
|
|
AccountBalancesResponse['balances'][0] |
|
|
>(); |
|
|
>(); |
|
|
|
|
|
|
|
|
public displayedColumns: string[] = ['date', 'value', 'actions']; |
|
|
public readonly accountId = input.required<string>(); |
|
|
|
|
|
public readonly displayedColumns: string[] = ['date', 'value', 'actions']; |
|
|
protected readonly locale = input(getLocale()); |
|
|
public readonly locale = input(getLocale()); |
|
|
protected readonly showActions = input(true); |
|
|
public readonly showActions = input(true); |
|
|
|
|
|
|
|
|
private dateAdapter = inject<DateAdapter<Date, string>>(DateAdapter); |
|
|
private dateAdapter = inject<DateAdapter<Date, string>>(DateAdapter); |
|
|
private notificationService = inject(NotificationService); |
|
|
private notificationService = inject(NotificationService); |
|
|
@ -126,7 +125,7 @@ export class GfAccountBalancesComponent implements OnChanges, OnInit { |
|
|
|
|
|
|
|
|
const accountBalance: CreateAccountBalanceDto = { |
|
|
const accountBalance: CreateAccountBalanceDto = { |
|
|
balance, |
|
|
balance, |
|
|
accountId: this.accountId, |
|
|
accountId: this.accountId(), |
|
|
date: format(date, DATE_FORMAT) |
|
|
date: format(date, DATE_FORMAT) |
|
|
}; |
|
|
}; |
|
|
|
|
|
|
|
|
|