rename transaction object to tx in transaction page
This commit is contained in:
parent
290e53f697
commit
3f1332ffca
@ -18,7 +18,7 @@
|
||||
<ion-row>
|
||||
<ion-col col-12>
|
||||
<h1>Transaction</h1>
|
||||
<p>{{ transaction.txid }}</p>
|
||||
<p>{{ tx.txid }}</p>
|
||||
</ion-col>
|
||||
</ion-row>
|
||||
<ion-row>
|
||||
@ -26,19 +26,19 @@
|
||||
</ion-row>
|
||||
<ion-row>
|
||||
<ion-col col-6>Size</ion-col>
|
||||
<ion-col col-6 text-right>{{ transaction.size }} (bytes)</ion-col>
|
||||
<ion-col col-6 text-right>{{ tx.size }} (bytes)</ion-col>
|
||||
</ion-row>
|
||||
<ion-row>
|
||||
<ion-col col-6>Received Time</ion-col>
|
||||
<ion-col col-6 text-right>{{ transaction.receivedTime }}</ion-col>
|
||||
<ion-col col-6 text-right>{{ tx.time * 1000 | date:'medium' }}</ion-col>
|
||||
</ion-row>
|
||||
<ion-row>
|
||||
<ion-col col-6>Mined Time</ion-col>
|
||||
<ion-col col-6 text-right>{{ transaction.minedTime }}</ion-col>
|
||||
<ion-col col-6 text-right>{{ tx.blocktime * 1000 | date:'medium' }}</ion-col>
|
||||
</ion-row>
|
||||
<ion-row>
|
||||
<ion-col col-6>Included in Block</ion-col>
|
||||
<ion-col col-6 text-right>{{ transaction.blockhash }}</ion-col>
|
||||
<ion-col col-6 text-right>{{ tx.blockhash }}</ion-col>
|
||||
</ion-row>
|
||||
<ion-row>
|
||||
<ion-col col-12><h2>Details</h2></ion-col>
|
||||
|
||||
@ -20,7 +20,7 @@ export class TransactionPage {
|
||||
|
||||
public loading: boolean = true;
|
||||
private txId: string;
|
||||
public transaction: any = {};
|
||||
public tx: any = {};
|
||||
|
||||
constructor(public navCtrl: NavController, public navParams: NavParams, private http: Http) {
|
||||
this.txId = navParams.get('txId');
|
||||
@ -31,8 +31,8 @@ export class TransactionPage {
|
||||
|
||||
this.http.get(apiPrefix + 'tx/' + this.txId).subscribe(
|
||||
(data) => {
|
||||
this.transaction = JSON.parse(data['_body']);
|
||||
console.log('transaction', this.transaction);
|
||||
this.tx = JSON.parse(data['_body']);
|
||||
console.log('tx', this.tx);
|
||||
this.loading = false;
|
||||
},
|
||||
(err) => {
|
||||
|
||||
Loading…
Reference in New Issue
Block a user