Add account object interface.

Add new vcard parser.
This commit is contained in:
Spencer Ofwiti
2021-03-02 10:29:14 +03:00
parent 2491dc54a0
commit 0d7f4aae13
9 changed files with 81 additions and 48 deletions

View File

@@ -54,12 +54,12 @@
matSortDirection="desc" matSortDisableClear>
<ng-container matColumnDef="name">
<mat-header-cell *matHeaderCellDef mat-sort-header> NAME </mat-header-cell>
<mat-cell *matCellDef="let user"> {{user?.vcard.fn}} </mat-cell>
<mat-cell *matCellDef="let user"> {{user?.vcard.fn[0].value}} </mat-cell>
</ng-container>
<ng-container matColumnDef="phone">
<mat-header-cell *matHeaderCellDef mat-sort-header> PHONE NUMBER </mat-header-cell>
<mat-cell *matCellDef="let user"> {{user?.vcard.tel[0].value[0]}} </mat-cell>
<mat-cell *matCellDef="let user"> {{user?.vcard.tel[0].value}} </mat-cell>
</ng-container>
<ng-container matColumnDef="created">

View File

@@ -14,7 +14,7 @@ import {Router} from '@angular/router';
export class AccountsComponent implements OnInit {
dataSource: MatTableDataSource<any>;
accounts: any[] = [];
displayedColumns = ['name', 'phone', 'created', 'balance', 'type', 'status', 'location', 'failedPinAttempts', 'select'];
displayedColumns = ['name', 'phone', 'created', 'location', 'select'];
initialSelection = [];
allowMultiSelect = true;
selection: SelectionModel<any>;