mirror of
https://github.com/pezkuwichain/pezkuwi-subxt.git
synced 2026-06-17 17:11:02 +00:00
Benchmark Collective Pallet (#5343)
* Init * Fix execute. * Duplicate macro for instances temporarilly * Add propose. * Add vote, close. * Propose from own module * Add old members to set_members. * Add previous proposals to propose. * Compress a bit the macro. Co-authored-by: Shawn Tabrizi <shawntabrizi@gmail.com>
This commit is contained in:
@@ -48,6 +48,9 @@ use frame_support::{
|
||||
};
|
||||
use frame_system::{self as system, ensure_signed, ensure_root};
|
||||
|
||||
#[cfg(feature = "runtime-benchmarks")]
|
||||
mod benchmarking;
|
||||
|
||||
/// Simple index type for proposal counting.
|
||||
pub type ProposalIndex = u32;
|
||||
|
||||
@@ -57,12 +60,12 @@ pub type ProposalIndex = u32;
|
||||
/// vote exactly once, therefore also the number of votes for any given motion.
|
||||
pub type MemberCount = u32;
|
||||
|
||||
pub trait Trait<I=DefaultInstance>: frame_system::Trait {
|
||||
pub trait Trait<I: Instance=DefaultInstance>: frame_system::Trait {
|
||||
/// The outer origin type.
|
||||
type Origin: From<RawOrigin<Self::AccountId, I>>;
|
||||
|
||||
/// The outer call dispatch type.
|
||||
type Proposal: Parameter + Dispatchable<Origin=<Self as Trait<I>>::Origin>;
|
||||
type Proposal: Parameter + Dispatchable<Origin=<Self as Trait<I>>::Origin> + From<Call<Self, I>>;
|
||||
|
||||
/// The outer event type.
|
||||
type Event: From<Event<Self, I>> + Into<<Self as frame_system::Trait>::Event>;
|
||||
|
||||
Reference in New Issue
Block a user