Skip to content

Commit

Permalink
Merge pull request #19 from reef-defi/identity
Browse files Browse the repository at this point in the history
Add Identity
  • Loading branch information
Netherdrake authored May 13, 2021
2 parents 51d5856 + c93aecc commit 6c4d5ff
Show file tree
Hide file tree
Showing 3 changed files with 69 additions and 1 deletion.
38 changes: 38 additions & 0 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

3 changes: 3 additions & 0 deletions runtime/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -70,6 +70,8 @@ pallet-offences = { version = "3.0.0", default-features = false }
sp-authority-discovery = { version = "3.0.0", default-features = false }
pallet-authority-discovery = { version = "3.0.0", default-features = false }

pallet-identity = { version = "3.0.0", default-features = false }


# PoC
pallet-collective = { version = "3.0.0", default-features = false }
Expand Down Expand Up @@ -130,6 +132,7 @@ std = [
"pallet-authority-discovery/std",
"pallet-im-online/std",
"pallet-offences/std",
"pallet-identity/std",

"sp-api/std",
"sp-block-builder/std",
Expand Down
29 changes: 28 additions & 1 deletion runtime/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -478,9 +478,33 @@ impl pallet_im_online::Config for Runtime {
type WeightInfo = ();
}

parameter_types! {
pub const BasicDeposit: Balance = 100 * REEF;
pub const FieldDeposit: Balance = 1 * REEF;
pub const SubAccountDeposit: Balance = 20 * REEF;
pub const MaxSubAccounts: u32 = 100;
pub const MaxAdditionalFields: u32 = 100;
pub const MaxRegistrars: u32 = 20;
}

impl pallet_identity::Config for Runtime {
type Event = Event;
type Currency = Balances;
type BasicDeposit = BasicDeposit;
type FieldDeposit = FieldDeposit;
type SubAccountDeposit = SubAccountDeposit;
type MaxSubAccounts = MaxSubAccounts;
type MaxAdditionalFields = MaxAdditionalFields;
type MaxRegistrars = MaxRegistrars;
type Slashed = ();
type ForceOrigin = EnsureRootOrTwoThridsTechCouncil;
type RegistrarOrigin = EnsureRootOrTwoThridsTechCouncil;
type WeightInfo = ();
}


parameter_types! {
pub const IndexDeposit: Balance = primitives::currency::DOLLARS;
pub const IndexDeposit: Balance = 1 * REEF;
}

impl pallet_indices::Config for Runtime {
Expand Down Expand Up @@ -789,6 +813,9 @@ construct_runtime!(
ImOnline: pallet_im_online::{Module, Call, Storage, Event<T>, ValidateUnsigned, Config<T>} = 37,
AuthorityDiscovery: pallet_authority_discovery::{Module, Call, Config} = 38,

// Identity
Identity: pallet_identity::{Module, Call, Storage, Event<T>} = 40,

// Proof of Commitment
TechCouncil: pallet_collective::<Instance1>::{Module, Call, Storage, Origin<T>, Event<T>, Config<T>} = 50,
Poc: module_poc::{Module, Call, Storage, Event<T>} = 51,
Expand Down

0 comments on commit 6c4d5ff

Please sign in to comment.