- Inverts sender and recipient addresses creating a request for transfer from recipient to sender.
126 lines
5.3 KiB
HTML
126 lines
5.3 KiB
HTML
<div *ngIf="transaction | async" class="mb-3 mt-1">
|
|
<div class="card text-center">
|
|
<mat-card-title class="card-header">
|
|
<div class="row">
|
|
TRANSACTION DETAILS
|
|
<button mat-raised-button type="button" class="btn btn-outline-secondary ml-auto mr-2" (click)="transaction = null"> CLOSE </button>
|
|
</div>
|
|
</mat-card-title>
|
|
<div *ngIf="transaction.type == 'transaction'" class="card-body">
|
|
<div class="row">
|
|
<div class="col-md-6">
|
|
<h4>Exchange: </h4>
|
|
<ul class="list-group list-group-flush">
|
|
<li class="list-group-item">
|
|
<span>Sender: {{transaction.sender?.vcard.fn[0].value}}</span><br><br>
|
|
<span>Sender Address: <a href="{{senderBloxbergLink}}" target="_blank"> {{transaction.from}} </a></span><br><br>
|
|
<button mat-raised-button color="primary" class="btn btn-outline-info" (click)="viewSender()">View Sender</button>
|
|
</li>
|
|
<li class="list-group-item">
|
|
<span>Recipient: {{transaction.recipient?.vcard.fn[0].value}}</span><br><br>
|
|
<span>Recipient Address: <a href="{{recipientBloxbergLink}}" target="_blank"> {{transaction.to}} </a></span><br><br>
|
|
<button mat-raised-button color="primary" class="btn btn-outline-info" (click)="viewRecipient()">View Recipient</button>
|
|
</li>
|
|
<li class="list-group-item">
|
|
<span>Amount: SRF {{transaction.value | tokenRatio}}</span>
|
|
</li>
|
|
</ul>
|
|
<h4 class="mt-2">Token: </h4>
|
|
<ul class="list-group list-group-flush">
|
|
<li class="list-group-item">
|
|
<span>Address: {{transaction.token._address}}</span>
|
|
</li>
|
|
<li class="list-group-item">
|
|
<span>Name: Sarafu Token</span>
|
|
</li>
|
|
<li class="list-group-item">
|
|
<span>Symbol: SRF</span>
|
|
</li>
|
|
</ul>
|
|
</div>
|
|
<div class="col-md-6">
|
|
<h4>Transaction: </h4>
|
|
<ul class="list-group list-group-flush">
|
|
<li class="list-group-item">
|
|
<span>Block: {{transaction.tx.block}}</span>
|
|
</li>
|
|
<li class="list-group-item">
|
|
<span>Index: {{transaction.tx.txIndex}}</span>
|
|
</li>
|
|
<li class="list-group-item">
|
|
<span>Hash: {{transaction.tx.txHash}}</span>
|
|
</li>
|
|
<li class="list-group-item">
|
|
<span>Success: {{transaction.tx.success}}</span>
|
|
</li>
|
|
<li class="list-group-item">
|
|
<span>Timestamp: {{transaction.tx.timestamp | date}}</span>
|
|
</li>
|
|
</ul><br>
|
|
<div class="mb-3">
|
|
<button mat-raised-button color="primary" type="button" class="btn btn-outline-success">Resend SMS</button>
|
|
</div>
|
|
<div>
|
|
<button mat-raised-button color="warn" type="button" class="btn btn-outline-danger">Reverse Transaction</button>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
<div *ngIf="transaction.type == 'conversion'" class="card-body">
|
|
<h3>Exchange: </h3>
|
|
<ul class="list-group list-group-flush">
|
|
<li class="list-group-item">
|
|
<span><strong>Trader: {{transaction.sender?.vcard.fn[0].value}}</strong></span>
|
|
</li>
|
|
<li class="list-group-item">
|
|
<span>Trader Address: {{transaction.trader}}</span>
|
|
</li>
|
|
</ul>
|
|
<button mat-raised-button color="primary" class="btn btn-outline-info" routerLink="/accounts/1">View Trader</button>
|
|
<br><br>
|
|
<div class="row">
|
|
<div class="col-md-6">
|
|
<h4>Source Token: </h4>
|
|
<ul class="list-group list-group-flush">
|
|
<li class="list-group-item">
|
|
<span>Address: {{transaction.sourceToken.address}}</span>
|
|
</li>
|
|
<li class="list-group-item">
|
|
<span>Name: {{transaction.sourceToken.name}}</span>
|
|
</li>
|
|
<li class="list-group-item">
|
|
<span>Symbol: {{transaction.sourceToken.symbol}}</span>
|
|
</li>
|
|
<li class="list-group-item">
|
|
<span>Amount: {{transaction.sourceToken.symbol + ' ' + transaction.fromValue}}</span>
|
|
</li>
|
|
</ul>
|
|
</div>
|
|
<div class="col-md-6">
|
|
<h4>Destination Token: </h4>
|
|
<ul class="list-group list-group-flush">
|
|
<li class="list-group-item">
|
|
<span>Address: {{transaction.destinationToken.address}}</span>
|
|
</li>
|
|
<li class="list-group-item">
|
|
<span>Name: {{transaction.destinationToken.name}}</span>
|
|
</li>
|
|
<li class="list-group-item">
|
|
<span>Symbol: {{transaction.destinationToken.symbol}}</span>
|
|
</li>
|
|
<li class="list-group-item">
|
|
<span>Amount: {{transaction.destinationToken.symbol + ' ' + transaction.toValue}}</span>
|
|
</li>
|
|
</ul>
|
|
</div>
|
|
<div class="col-md-6">
|
|
<button mat-raised-button color="primary" type="button" class="btn btn-outline-success">Resend SMS</button>
|
|
</div>
|
|
<div class="col-md-6">
|
|
<button mat-raised-button color="warn" type="button" class="btn btn-outline-danger ml-2" (click)="reverseTransaction()">Reverse Transaction</button>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
</div>
|