17 data_service_factory_i& services)
19 , _account_service(services.account_service())
20 , _post_budget_service(services.post_budget_service())
21 , _banner_budget_service(services.banner_budget_service())
22 , _adv_property_service(services.advertising_property_service())
32 close_budget(_post_budget_service, op);
34 case budget_type::banner:
35 close_budget(_banner_budget_service, op);
40 template <protocol::budget_type budget_type_v>
42 const operation_type& op)
46 auto& current_moderator = _adv_property_service.
get().moderator;
47 FC_ASSERT(current_moderator != SCORUM_MISSING_MODERATOR_ACCOUNT,
"Advertising moderator was not set");
48 FC_ASSERT(current_moderator == op.moderator,
"User ${1} is not the advertising moderator", (
"1", op.moderator));
49 FC_ASSERT(budget_svc.
is_exists(op.uuid),
"Budget with id ${id} doesn't exist", (
"id", op.uuid));
close_budget_by_advertising_moderator_evaluator(data_service_factory_i &services)
void do_apply(const operation_type &op)
virtual void check_account_existence(const account_name_type &, const optional< const char * > &context_type_name=optional< const char * >()) const =0
virtual bool is_exists(const uuid_type &uuid) const =0
virtual void finish_budget(const uuid_type &uuid)=0
virtual const object_type & get() const =0
Closes advertising budget by moderator, remaining funds will be returned to creator.