mirror of
https://github.com/status-im/status-desktop.git
synced 2025-01-10 14:26:34 +00:00
fix(@wallet): add data field in tx event
This commit is contained in:
parent
bc353a1ccc
commit
36f562243c
@ -137,6 +137,7 @@ const getSuggestedRoutesTask*: Task = proc(argEncoded: string) {.gcsafe, nimcall
|
||||
|
||||
type
|
||||
WatchTransactionTaskArg* = ref object of QObjectTaskArg
|
||||
data: string
|
||||
hash: string
|
||||
chainId: int
|
||||
address: string
|
||||
@ -147,6 +148,7 @@ const watchTransactionTask*: Task = proc(argEncoded: string) {.gcsafe, nimcall.}
|
||||
try:
|
||||
let output = %*{
|
||||
"hash": arg.hash,
|
||||
"data": arg.data,
|
||||
"address": arg.address,
|
||||
"chainId": arg.chainId,
|
||||
"trxType": arg.trxType,
|
||||
@ -156,6 +158,7 @@ const watchTransactionTask*: Task = proc(argEncoded: string) {.gcsafe, nimcall.}
|
||||
except Exception as e:
|
||||
let output = %* {
|
||||
"hash": arg.hash,
|
||||
"data": arg.data,
|
||||
"address": arg.address,
|
||||
"chainId": arg.chainId,
|
||||
"trxType": arg.trxType,
|
||||
|
@ -147,8 +147,9 @@ QtObject:
|
||||
let transactionReceipt = transactions.getTransactionReceipt(chainId, hash).result
|
||||
if transactionReceipt != nil and transactionReceipt.kind != JNull:
|
||||
discard transactions.deletePendingTransaction(chainId, hash)
|
||||
echo watchTxResult["data"].getStr
|
||||
let ev = TransactionMinedArgs(
|
||||
data: "",
|
||||
data: watchTxResult["data"].getStr,
|
||||
transactionHash: hash,
|
||||
chainId: chainId,
|
||||
success: transactionReceipt{"status"}.getStr == "0x1",
|
||||
@ -171,6 +172,7 @@ QtObject:
|
||||
hash: hash,
|
||||
address: fromAddress,
|
||||
trxType: trxType,
|
||||
data: data,
|
||||
tptr: cast[ByteAddress](watchTransactionTask),
|
||||
vptr: cast[ByteAddress](self.vptr),
|
||||
slot: "watchTransactionResult",
|
||||
|
Loading…
x
Reference in New Issue
Block a user