Fix null timestamps on transaction previews
This commit is contained in:
parent
5922ff0f40
commit
80dfa0e937
@ -23,7 +23,7 @@
|
|||||||
<app-amount [satoshis]="totalValue"></app-amount>
|
<app-amount [satoshis]="totalValue"></app-amount>
|
||||||
</ng-template>
|
</ng-template>
|
||||||
</span>
|
</span>
|
||||||
<span class="field col-sm-4 text-center">‎{{ (tx.status.confirmed ? tx.status.block_time : transactionTime) * 1000 | date:'yyyy-MM-dd HH:mm' }}</span>
|
<span class="field col-sm-4 text-center"><ng-container *ngIf="transactionTime > 0">‎{{ transactionTime * 1000 | date:'yyyy-MM-dd HH:mm' }}</ng-container></span>
|
||||||
<span class="field col-sm-4 text-right"><span class="label" i18n="transaction.fee|Transaction fee">Fee </span>{{ tx.fee | number }} <span class="symbol" i18n="shared.sat|sat">sat</span></span>
|
<span class="field col-sm-4 text-right"><span class="label" i18n="transaction.fee|Transaction fee">Fee </span>{{ tx.fee | number }} <span class="symbol" i18n="shared.sat|sat">sat</span></span>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
|
@ -165,7 +165,10 @@ export class TransactionPreviewComponent implements OnInit, OnDestroy {
|
|||||||
this.opReturns = this.getOpReturns(this.tx);
|
this.opReturns = this.getOpReturns(this.tx);
|
||||||
this.extraData = this.chooseExtraData();
|
this.extraData = this.chooseExtraData();
|
||||||
|
|
||||||
if (!tx.status.confirmed && tx.firstSeen) {
|
if (tx.status.confirmed) {
|
||||||
|
this.transactionTime = tx.status.block_time;
|
||||||
|
this.openGraphService.waitOver('tx-time-' + this.txId);
|
||||||
|
} else if (!tx.status.confirmed && tx.firstSeen) {
|
||||||
this.transactionTime = tx.firstSeen;
|
this.transactionTime = tx.firstSeen;
|
||||||
this.openGraphService.waitOver('tx-time-' + this.txId);
|
this.openGraphService.waitOver('tx-time-' + this.txId);
|
||||||
} else {
|
} else {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user