Refactor transactions table to show address before loading account meta.
This commit is contained in:
parent
9782c919d5
commit
16af939af7
@ -3,7 +3,7 @@ import Web3 from 'web3';
|
||||
import { environment } from '@src/environments/environment';
|
||||
|
||||
@Injectable({
|
||||
providedIn: 'root'
|
||||
providedIn: 'root',
|
||||
})
|
||||
export class Web3Service {
|
||||
private static web3: Web3;
|
||||
|
@ -121,8 +121,10 @@ export class AccountDetailsComponent implements OnInit {
|
||||
location: this.account.location.area,
|
||||
locationType: this.account.location.area_type,
|
||||
});
|
||||
this.userService.getAccountStatus(this.account.vcard?.tel[0].value).pipe(first())
|
||||
.subscribe(response => this.accountStatus = response.status);
|
||||
this.userService
|
||||
.getAccountStatus(this.account.vcard?.tel[0].value)
|
||||
.pipe(first())
|
||||
.subscribe((response) => (this.accountStatus = response.status));
|
||||
} else {
|
||||
alert('Account not found!');
|
||||
}
|
||||
|
@ -48,12 +48,12 @@
|
||||
|
||||
<ng-container matColumnDef="sender">
|
||||
<th mat-header-cell *matHeaderCellDef mat-sort-header> Sender </th>
|
||||
<td mat-cell *matCellDef="let transaction"> {{transaction?.sender?.vcard.fn[0].value}} </td>
|
||||
<td mat-cell *matCellDef="let transaction"> {{transaction?.sender?.vcard.fn[0].value || transaction.from}} </td>
|
||||
</ng-container>
|
||||
|
||||
<ng-container matColumnDef="recipient">
|
||||
<th mat-header-cell *matHeaderCellDef mat-sort-header> Recipient </th>
|
||||
<td mat-cell *matCellDef="let transaction"> {{transaction?.recipient?.vcard.fn[0].value}} </td>
|
||||
<td mat-cell *matCellDef="let transaction"> {{transaction?.recipient?.vcard.fn[0].value || transaction.to }} </td>
|
||||
</ng-container>
|
||||
|
||||
<ng-container matColumnDef="value">
|
||||
|
Loading…
Reference in New Issue
Block a user