added transaction and address search to blocksPage
This commit is contained in:
parent
8a0d065296
commit
c1523966f8
@ -30,10 +30,6 @@ export class TransactionListComponent {
|
||||
(data) => {
|
||||
this.transactions = JSON.parse(data['_body']);
|
||||
this.loading = false;
|
||||
|
||||
this.transactions.txs.forEach((tx) => {
|
||||
console.log('tx is', tx);
|
||||
});
|
||||
},
|
||||
(err) => {
|
||||
console.log('err is', err);
|
||||
|
||||
@ -37,16 +37,24 @@ export class BlocksPage {
|
||||
},
|
||||
() => {
|
||||
this.http.get(apiPrefix + 'tx/' + this.q).subscribe(
|
||||
(data: any) => {
|
||||
function (data: any) {
|
||||
this.resetSearch();
|
||||
console.log('tx', data);
|
||||
},
|
||||
let parsedData: any = JSON.parse(data._body);
|
||||
this.navCtrl.push('transaction', {
|
||||
'txId': parsedData.txid
|
||||
});
|
||||
}.bind(this),
|
||||
() => {
|
||||
this.http.get(apiPrefix + 'addr/' + this.q).subscribe(
|
||||
(data: any) => {
|
||||
function (data: any) {
|
||||
this.resetSearch();
|
||||
console.log('addr', data);
|
||||
},
|
||||
let parsedData: any = JSON.parse(data._body);
|
||||
this.navCtrl.push('address', {
|
||||
'addrStr': parsedData.addrStr
|
||||
});
|
||||
}.bind(this),
|
||||
() => {
|
||||
this.http.get(apiPrefix + 'block-index/' + this.q).subscribe(
|
||||
function (data: any): void {
|
||||
|
||||
Loading…
Reference in New Issue
Block a user