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