mirror of
https://github.com/cypherstack/stack_wallet.git
synced 2024-12-23 20:09:23 +00:00
testing
This commit is contained in:
parent
9d01f0beaa
commit
65882b66e1
1 changed files with 12 additions and 5 deletions
|
@ -11,6 +11,7 @@
|
||||||
import 'dart:async';
|
import 'dart:async';
|
||||||
import 'dart:typed_data';
|
import 'dart:typed_data';
|
||||||
|
|
||||||
|
import 'package:bitbox/bitbox.dart' as bb;
|
||||||
import 'package:bitcoindart/bitcoindart.dart';
|
import 'package:bitcoindart/bitcoindart.dart';
|
||||||
import 'package:flutter/material.dart';
|
import 'package:flutter/material.dart';
|
||||||
import 'package:flutter_riverpod/flutter_riverpod.dart';
|
import 'package:flutter_riverpod/flutter_riverpod.dart';
|
||||||
|
@ -478,20 +479,26 @@ class HiddenSettings extends StatelessWidget {
|
||||||
final p2pkh =
|
final p2pkh =
|
||||||
P2PKH(data: pd, network: bitcoincash);
|
P2PKH(data: pd, network: bitcoincash);
|
||||||
|
|
||||||
final addr = p2pkh.data.address!;
|
// final addr = p2pkh.data.address!;
|
||||||
|
|
||||||
|
final addr = bb.Address.toLegacyAddress(
|
||||||
|
"bitcoincash:qp352c2skpdxwzzd090mec3v37au5dmfwgwfw686sz",
|
||||||
|
);
|
||||||
|
|
||||||
final scripthash =
|
final scripthash =
|
||||||
AddressUtils.convertToScriptHash(
|
AddressUtils.convertToScriptHash(
|
||||||
addr, bitcoincash);
|
addr, bitcoincash);
|
||||||
|
|
||||||
final hist = await e.getHistory(
|
|
||||||
scripthash: scripthash);
|
|
||||||
|
|
||||||
Util.printJson(hist, "HISTORY for $address");
|
|
||||||
final utxos =
|
final utxos =
|
||||||
await e.getUTXOs(scripthash: scripthash);
|
await e.getUTXOs(scripthash: scripthash);
|
||||||
|
|
||||||
Util.printJson(utxos, "UTXOS for $address");
|
Util.printJson(utxos, "UTXOS for $address");
|
||||||
|
|
||||||
|
final hist = await e.getTransaction(
|
||||||
|
txHash: utxos.first["tx_hash"] as String,
|
||||||
|
);
|
||||||
|
|
||||||
|
Util.printJson(hist, "HISTORY for $address");
|
||||||
} catch (e, s) {
|
} catch (e, s) {
|
||||||
print("$e\n$s");
|
print("$e\n$s");
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue