fix: add recurring and fixed account table in clients view section (#956)

Fixes: #955
This commit is contained in:
Muskan Khedia
2020-06-30 10:21:48 +05:30
committed by GitHub
parent ce8ca77ad7
commit 7bd84899cf
7 changed files with 300 additions and 31 deletions
@@ -29,7 +29,7 @@ export class LoanAccountTableComponent implements OnInit {
/** Loan Account Setter */
@Input() set loanAccountData(data: any) {
this.accountData = data;
const filteredAccountData = this.accountsFilterPipe.transform(data, 'loan', this.showClosed ? 'closed' : 'open');
const filteredAccountData = this.accountsFilterPipe.transform(data, 'loan', this.showClosed ? 'closed' : 'open', 'isLoan');
this.dataSource = new MatTableDataSource(filteredAccountData);
this.dataSource.paginator = this.paginator;
this.dataSource.sort = this.sort;
@@ -56,7 +56,7 @@ export class LoanAccountTableComponent implements OnInit {
*/
toggleClosed() {
this.showClosed = !this.showClosed;
const filteredAccountData = this.accountsFilterPipe.transform(this.accountData, 'loan', this.showClosed ? 'closed' : 'open');
const filteredAccountData = this.accountsFilterPipe.transform(this.accountData, 'loan', this.showClosed ? 'closed' : 'open', 'isLoan');
this.dataSource = new MatTableDataSource(filteredAccountData);
this.dataSource.paginator = this.paginator;
this.dataSource.sort = this.sort;
@@ -29,7 +29,7 @@ export class SavingsAccountTableComponent implements OnInit {
/** Savings Account Setter */
@Input() set savingsAccountData(data: any) {
this.accountData = data;
const filteredAccountData = this.accountsFilterPipe.transform(data, 'saving', this.showClosed ? 'closed' : 'open');
const filteredAccountData = this.accountsFilterPipe.transform(data, 'saving', this.showClosed ? 'closed' : 'open', 'isSavings');
this.dataSource = new MatTableDataSource(filteredAccountData);
this.dataSource.paginator = this.paginator;
this.dataSource.sort = this.sort;
@@ -56,7 +56,7 @@ export class SavingsAccountTableComponent implements OnInit {
*/
toggleClosed() {
this.showClosed = !this.showClosed;
const filteredAccountData = this.accountsFilterPipe.transform(this.accountData, 'saving', this.showClosed ? 'closed' : 'open');
const filteredAccountData = this.accountsFilterPipe.transform(this.accountData, 'saving', this.showClosed ? 'closed' : 'open', 'isSavings');
this.dataSource = new MatTableDataSource(filteredAccountData);
this.dataSource.paginator = this.paginator;
this.dataSource.sort = this.sort;
@@ -29,7 +29,7 @@ export class ShareAccountTableComponent implements OnInit {
/** Share Account Setter */
@Input() set shareAccountData(data: any) {
this.accountData = data;
const filteredAccountData = this.accountsFilterPipe.transform(data, 'share', this.showClosed ? 'closed' : 'open');
const filteredAccountData = this.accountsFilterPipe.transform(data, 'share', this.showClosed ? 'closed' : 'open', 'isShare');
this.dataSource = new MatTableDataSource(filteredAccountData);
this.dataSource.paginator = this.paginator;
this.dataSource.sort = this.sort;
@@ -56,7 +56,7 @@ export class ShareAccountTableComponent implements OnInit {
*/
toggleClosed() {
this.showClosed = !this.showClosed;
const filteredAccountData = this.accountsFilterPipe.transform(this.accountData, 'share', this.showClosed ? 'closed' : 'open');
const filteredAccountData = this.accountsFilterPipe.transform(this.accountData, 'share', this.showClosed ? 'closed' : 'open', 'isShare');
this.dataSource = new MatTableDataSource(filteredAccountData);
this.dataSource.paginator = this.paginator;
this.dataSource.sort = this.sort;