15 const asset& maximum_bonus,
18 FC_ASSERT(supply >
asset(0,
SCORUM_SYMBOL),
"Registration supply amount must be more than zerro.");
19 FC_ASSERT(maximum_bonus >
asset(0,
SCORUM_SYMBOL),
"Registration maximum bonus amount must be more than zerro.");
20 FC_ASSERT(!schedule_items.empty(),
"Registration schedule must have at least one item.");
23 for (
const auto& value : schedule_items)
25 const auto& stage = value.first;
27 FC_ASSERT(item.
users > 0,
"Invalid schedule value (users in thousands) for stage ${1}.", (
"1", stage));
29 "Invalid schedule value (percent) for stage ${1}.", (
"1", stage));
34 FC_ASSERT(!
is_exists(),
"Can't create more than one pool.");
41 for (
const auto& value : schedule_items)
tracks the blockchain state in an extensible manner
dba::db_index & db_impl()
void increase_already_allocated_count() override
void decrease_balance(const asset &amount) override
const registration_pool_object & create_pool(const asset &supply, const asset &maximum_bonus, const schedule_items_type &schedule_items) override
dbs_registration_pool(database &db)
virtual const object_type & create(const modifier_type &modifier) override
virtual void update(const modifier_type &modifier) override
virtual const object_type & get() const override
virtual bool is_exists() const override
fc::shared_vector< schedule_item > schedule_items
uint64_t already_allocated_count
std::map< uint8_t, schedule_item_type > schedule_items_type