difftreelog
Field name changed
in: master
4 files changed
Cargo.lockdiffbeforeafterboth2804 "pallet-grandpa",2804 "pallet-grandpa",2805 "pallet-nft",2805 "pallet-nft",2806 "pallet-randomness-collective-flip",2806 "pallet-randomness-collective-flip",2807 "pallet-staking",2807 "pallet-sudo",2808 "pallet-sudo",2808 "pallet-timestamp",2809 "pallet-timestamp",2809 "pallet-transaction-payment",2810 "pallet-transaction-payment",3004 "sp-timestamp",3005 "sp-timestamp",3005]3006]30073008[[package]]3009name = "pallet-authorship"3010version = "2.0.0-rc4"3011source = "git+https://github.com/paritytech/substrate.git?tag=v2.0.0-rc4#00768a1f21a579c478fe5d4f51e1fa71f7db9fd4"3012dependencies = [3013 "frame-support",3014 "frame-system",3015 "impl-trait-for-tuples",3016 "parity-scale-codec",3017 "sp-authorship",3018 "sp-inherents",3019 "sp-runtime",3020 "sp-std",3021]300630223007[[package]]3023[[package]]3008name = "pallet-balances"3024name = "pallet-balances"3160 "sp-trie",3176 "sp-trie",3161]3177]31783179[[package]]3180name = "pallet-staking"3181version = "2.0.0-rc4"3182source = "git+https://github.com/paritytech/substrate.git?tag=v2.0.0-rc4#00768a1f21a579c478fe5d4f51e1fa71f7db9fd4"3183dependencies = [3184 "frame-support",3185 "frame-system",3186 "pallet-authorship",3187 "pallet-session",3188 "parity-scale-codec",3189 "serde",3190 "sp-application-crypto",3191 "sp-io",3192 "sp-npos-elections",3193 "sp-runtime",3194 "sp-staking",3195 "sp-std",3196 "static_assertions",3197]316231983163[[package]]3199[[package]]3164name = "pallet-sudo"3200name = "pallet-sudo"5359 "sp-std",5395 "sp-std",5360]5396]53975398[[package]]5399name = "sp-authorship"5400version = "2.0.0-rc4"5401source = "git+https://github.com/paritytech/substrate.git?tag=v2.0.0-rc4#00768a1f21a579c478fe5d4f51e1fa71f7db9fd4"5402dependencies = [5403 "parity-scale-codec",5404 "sp-inherents",5405 "sp-runtime",5406 "sp-std",5407]536154085362[[package]]5409[[package]]5363name = "sp-block-builder"5410name = "sp-block-builder"5576 "strum",5623 "strum",5577]5624]56255626[[package]]5627name = "sp-npos-elections"5628version = "2.0.0-rc4"5629source = "git+https://github.com/paritytech/substrate.git?tag=v2.0.0-rc4#00768a1f21a579c478fe5d4f51e1fa71f7db9fd4"5630dependencies = [5631 "parity-scale-codec",5632 "serde",5633 "sp-arithmetic",5634 "sp-npos-elections-compact",5635 "sp-std",5636]56375638[[package]]5639name = "sp-npos-elections-compact"5640version = "2.0.0-rc4"5641source = "git+https://github.com/paritytech/substrate.git?tag=v2.0.0-rc4#00768a1f21a579c478fe5d4f51e1fa71f7db9fd4"5642dependencies = [5643 "proc-macro-crate",5644 "proc-macro2",5645 "quote 1.0.7",5646 "syn 1.0.31",5647]557856485579[[package]]5649[[package]]5580name = "sp-offchain"5650name = "sp-offchain"pallets/nft/src/lib.rsdiffbeforeafterboth--- a/pallets/nft/src/lib.rs
+++ b/pallets/nft/src/lib.rs
@@ -26,7 +26,7 @@
pub next_item_id: u64,
pub name: Vec<u16>, // 64 include null escape char
pub description: Vec<u16>, // 256 include null escape char
- pub token_trefix: Vec<u8>, // 16 include null escape char
+ pub token_prefix: Vec<u8>, // 16 include null escape char
pub custom_data_size: u32,
}
@@ -125,9 +125,9 @@
description.push(0);
ensure!(name.len() <= 256, "Collection description can not be longer than 255 char");
- let mut token_trefix = token_prefix.to_vec();
- token_trefix.push(0);
- ensure!(token_trefix.len() <= 16, "Token prefix can not be longer than 15 char");
+ let mut prefix = token_prefix.to_vec();
+ prefix.push(0);
+ ensure!(prefix.len() <= 16, "Token prefix can not be longer than 15 char");
// Generate next collection ID
let next_id = NextCollectionID::get();
@@ -139,7 +139,7 @@
owner: who.clone(),
name: name,
description: description,
- token_trefix: token_trefix,
+ token_prefix: prefix,
next_item_id: next_id,
custom_data_size: custom_data_sz,
};
runtime/Cargo.tomldiffbeforeafterboth--- a/runtime/Cargo.toml
+++ b/runtime/Cargo.toml
@@ -27,6 +27,7 @@
'sudo/std',
'system/std',
'timestamp/std',
+ 'staking/std',
'transaction-payment/std',
'nft/std',
]
@@ -201,6 +202,14 @@
tag = 'v2.0.0-rc4'
version = '2.0.0-rc4'
+
+[dependencies.staking]
+default-features = false
+git = 'https://github.com/paritytech/substrate.git'
+package = 'pallet-staking'
+tag = 'v2.0.0-rc4'
+version = '2.0.0-rc4'
+
[dependencies.transaction-payment]
default-features = false
git = 'https://github.com/paritytech/substrate.git'
runtime/src/lib.rsdiffbeforeafterboth--- a/runtime/src/lib.rs
+++ b/runtime/src/lib.rs
@@ -30,6 +30,7 @@
#[cfg(any(feature = "std", test))]
pub use sp_runtime::BuildStorage;
pub use timestamp::Call as TimestampCall;
+pub use staking::Call as StakingCall;
pub use balances::Call as BalancesCall;
pub use sp_runtime::{Permill, Perbill};
pub use contracts::Schedule as ContractsSchedule;
@@ -229,6 +230,33 @@
type MinimumPeriod = MinimumPeriod;
}
+
+parameter_types! {
+ pub const TombstoneDeposit: Balance = 16 * MILLICENTS;
+ pub const RentByteFee: Balance = 4 * MILLICENTS;
+ pub const RentDepositOffset: Balance = 1000 * MILLICENTS;
+ pub const SurchargeReward: Balance = 150 * MILLICENTS;
+}
+
+impl contracts::Trait for Runtime {
+ type Time = Timestamp;
+ type Randomness = RandomnessCollectiveFlip;
+ type Currency = Balances;
+ type Event = Event;
+ type DetermineContractAddress = contracts::SimpleAddressDeterminer<Runtime>;
+ type TrieIdGenerator = contracts::TrieIdFromParentCounter<Runtime>;
+ type RentPayment = ();
+ type SignedClaimHandicap = contracts::DefaultSignedClaimHandicap;
+ type TombstoneDeposit = TombstoneDeposit;
+ type StorageSizeOffset = contracts::DefaultStorageSizeOffset;
+ type RentByteFee = RentByteFee;
+ type RentDepositOffset = RentDepositOffset;
+ type SurchargeReward = SurchargeReward;
+ type MaxDepth = contracts::DefaultMaxDepth;
+ type MaxValueSize = contracts::DefaultMaxValueSize;
+ type WeightPrice = transaction_payment::Module<Self>;
+}
+
parameter_types! {
pub const ExistentialDeposit: u128 = 500;
}
@@ -260,32 +288,6 @@
type Call = Call;
}
-parameter_types! {
- pub const TombstoneDeposit: Balance = 16 * MILLICENTS;
- pub const RentByteFee: Balance = 4 * MILLICENTS;
- pub const RentDepositOffset: Balance = 1000 * MILLICENTS;
- pub const SurchargeReward: Balance = 150 * MILLICENTS;
-}
-
-impl contracts::Trait for Runtime {
- type Time = Timestamp;
- type Randomness = RandomnessCollectiveFlip;
- type Currency = Balances;
- type Event = Event;
- type DetermineContractAddress = contracts::SimpleAddressDeterminer<Runtime>;
- type TrieIdGenerator = contracts::TrieIdFromParentCounter<Runtime>;
- type RentPayment = ();
- type SignedClaimHandicap = contracts::DefaultSignedClaimHandicap;
- type TombstoneDeposit = TombstoneDeposit;
- type StorageSizeOffset = contracts::DefaultStorageSizeOffset;
- type RentByteFee = RentByteFee;
- type RentDepositOffset = RentDepositOffset;
- type SurchargeReward = SurchargeReward;
- type MaxDepth = contracts::DefaultMaxDepth;
- type MaxValueSize = contracts::DefaultMaxValueSize;
- type WeightPrice = transaction_payment::Module<Self>;
-}
-
/// Used for the module template in `./template.rs`
impl nft::Trait for Runtime {
type Event = Event;
@@ -306,6 +308,7 @@
Balances: balances::{Module, Call, Storage, Config<T>, Event<T>},
TransactionPayment: transaction_payment::{Module, Storage},
Sudo: sudo::{Module, Call, Config<T>, Storage, Event<T>},
+ // Staking: staking::{Module, Call, Config<T>, Storage, Event<T>},
// Used for the module template in `./template.rs`
Nft: nft::{Module, Call, Storage, Event<T>},
}