decouple balances from some modules (#1641)

* decouple balances from some module by creating a new traits in support/traits
* improve decl_event
This commit is contained in:
thiolliere
2019-02-08 17:43:12 +01:00
committed by GitHub
parent 83f9e1e720
commit e5dbcf6890
19 changed files with 510 additions and 341 deletions
+5 -2
View File
@@ -65,8 +65,8 @@ pub const VERSION: RuntimeVersion = RuntimeVersion {
spec_name: create_runtime_str!("node"),
impl_name: create_runtime_str!("substrate-node"),
authoring_version: 10,
spec_version: 24,
impl_version: 24,
spec_version: 25,
impl_version: 25,
apis: RUNTIME_API_VERSIONS,
};
@@ -141,11 +141,13 @@ impl session::Trait for Runtime {
}
impl staking::Trait for Runtime {
type Currency = balances::Module<Self>;
type OnRewardMinted = Treasury;
type Event = Event;
}
impl democracy::Trait for Runtime {
type Currency = balances::Module<Self>;
type Proposal = Call;
type Event = Event;
}
@@ -165,6 +167,7 @@ impl council::motions::Trait for Runtime {
}
impl treasury::Trait for Runtime {
type Currency = balances::Module<Self>;
type ApproveOrigin = council_motions::EnsureMembers<_4>;
type RejectOrigin = council_motions::EnsureMembers<_2>;
type Event = Event;