From a13723fa3c3dd2a155c64447cd1e5daef58dcecf Mon Sep 17 00:00:00 2001 From: Kapis Date: Thu, 16 Mar 2023 18:45:34 +0100 Subject: [PATCH] showing hash in json output --- lib/gvaHistory.py | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/lib/gvaHistory.py b/lib/gvaHistory.py index 3245467..9e14e90 100755 --- a/lib/gvaHistory.py +++ b/lib/gvaHistory.py @@ -47,6 +47,7 @@ class History: outputs comment writtenTime + hash } } } @@ -59,6 +60,7 @@ class History: outputs receivedTime blockstamp + hash } sending { currency @@ -67,6 +69,7 @@ class History: outputs receivedTime blockstamp + hash } } balance(script: $script) { @@ -138,6 +141,7 @@ class History: trans[i].append(transaction['comment']) trans[i].append(base) trans[i].append(transaction['blockstamp']) + trans[i].append(transaction['hash']) i += 1 # Parse transactions in mempool @@ -169,6 +173,7 @@ class History: trans[i].append(transaction['comment']) trans[i].append(base) trans[i].append(transaction['blockstamp']) + trans[i].append(transaction['hash']) i += 1 # Order transactions by date @@ -270,6 +275,7 @@ class History: dailyJSON[i]['amountUD'] = trans[4] dailyJSON[i]['comment'] = trans[5] dailyJSON[i]['blockstamp'] = trans[7] + dailyJSON[i]['hash'] = trans[8] dailyJSON = json.dumps(dailyJSON, indent=2) # If we want to write JSON to a file