Skip to content
Snippets Groups Projects
Commit d98c320d authored by alexey.stratulat's avatar alexey.stratulat
Browse files

[+] Added input item TX_ITEM_TYPE_VOTE AND TX_ITEM_TYPE_VOTING for function...

[+] Added input item TX_ITEM_TYPE_VOTE AND TX_ITEM_TYPE_VOTING for function dap_chain_datum_tx_to_json.
parent 3615c10d
No related branches found
No related tags found
2 merge requests!1488Feature 10430_2,!1485Feature 10430
Pipeline #36083 passed with stage
in 10 minutes and 52 seconds
This commit is part of merge request !1485. Comments created here will be created in the context of that merge request.
......@@ -9,6 +9,7 @@
#include "dap_json_rpc_chain_datum_tx_items.h"
#include "dap_json_rpc_chain_datum_tx_receipt.h"
#include "json.h"
#include "dap_chain_datum_tx_voting.h"
#define LOG_TAG "dap_json_rpc_chain_datum_tx"
......@@ -107,6 +108,14 @@ json_object *dap_chain_datum_tx_to_json(dap_chain_datum_tx_t *a_tx){
l_obj_item_type = json_object_new_string("TX_ITEM_TYPE_TSD");
l_obj_item_data = dap_chain_datum_tx_item_tsd_to_json((dap_chain_tx_tsd_t*)item);
break;
case TX_ITEM_TYPE_VOTE:
l_obj_item_type = json_object_new_string("TX_ITEM_TYPE_VOTE");
l_obj_item_data = dap_chain_datum_tx_item_vote_to_json((dap_chain_tx_vote_t*)item);
break;
case TX_ITEM_TYPE_VOTING:
l_obj_item_type = json_object_new_string("TX_ITEM_TYPE_VOTING");
l_obj_item_data = dap_chain_datum_tx_item_voting_tsd_to_json(a_tx);
break;
default: {
char *l_hash_str;
dap_get_data_hash_str_static(a_tx, dap_chain_datum_tx_get_size(a_tx), l_hash_str);
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment