Add timestamp field to sidechain transaction object
This commit is contained in:
parent
5a3d851a38
commit
524f409f81
3 changed files with 3 additions and 2 deletions
|
|
@ -26,6 +26,7 @@ namespace graphene { namespace chain {
|
|||
static const uint8_t space_id = protocol_ids;
|
||||
static const uint8_t type_id = sidechain_transaction_object_type;
|
||||
|
||||
time_point_sec timestamp;
|
||||
sidechain_type sidechain = sidechain_type::unknown;
|
||||
object_id_type object_id;
|
||||
std::string transaction;
|
||||
|
|
@ -70,6 +71,7 @@ FC_REFLECT_ENUM( graphene::chain::sidechain_transaction_status,
|
|||
(settled) )
|
||||
|
||||
FC_REFLECT_DERIVED( graphene::chain::sidechain_transaction_object, (graphene::db::object ),
|
||||
(timestamp)
|
||||
(sidechain)
|
||||
(object_id)
|
||||
(transaction)
|
||||
|
|
|
|||
|
|
@ -28,6 +28,7 @@ void_result sidechain_transaction_create_evaluator::do_evaluate(const sidechain_
|
|||
object_id_type sidechain_transaction_create_evaluator::do_apply(const sidechain_transaction_create_operation &op)
|
||||
{ try {
|
||||
const auto &new_sidechain_transaction_object = db().create<sidechain_transaction_object>([&](sidechain_transaction_object &sto) {
|
||||
sto.timestamp = db().head_block_time();
|
||||
sto.sidechain = op.sidechain;
|
||||
sto.object_id = op.object_id;
|
||||
sto.transaction = op.transaction;
|
||||
|
|
|
|||
|
|
@ -1,2 +0,0 @@
|
|||
#!/bin/bash
|
||||
find . -regex ".*[c|h]pp" | xargs clang-format -i
|
||||
Loading…
Reference in a new issue