use crate::AccountId;
use frame_support::traits::EitherOfDiverse;
use frame_system::EnsureRoot;
pub type OracleMembershipInst = pallet_membership::Instance1;
pub type MainCouncilMembershipInst = pallet_membership::Instance2;
pub type TechnicalCommitteeMembershipInst = pallet_membership::Instance3;
pub type CommunityCouncilMembershipInst = pallet_membership::Instance4;
pub type MainCouncilCollectiveInst = pallet_collective::Instance2;
pub type TechnicalCommitteeCollectiveInst = pallet_collective::Instance3;
pub type CommunityCouncilCollectiveInst = pallet_collective::Instance4;
pub type MainTreasuryInst = pallet_treasury::Instance1;
pub type CommunityTreasuryInst = pallet_treasury::Instance2;
pub type EnsureRootOrAllMainCouncil = EitherOfDiverse<
EnsureRoot<AccountId>,
pallet_collective::EnsureProportionAtLeast<AccountId, MainCouncilCollectiveInst, 1, 1>,
>;
pub type EnsureRootOrTwoThirdsMainCouncil = EitherOfDiverse<
EnsureRoot<AccountId>,
pallet_collective::EnsureProportionAtLeast<AccountId, MainCouncilCollectiveInst, 2, 3>,
>;
pub type EnsureRootOrHalfMainCouncil = EitherOfDiverse<
EnsureRoot<AccountId>,
pallet_collective::EnsureProportionAtLeast<AccountId, MainCouncilCollectiveInst, 1, 2>,
>;
pub type EnsureRootOrAllTechnicalCommittee = EitherOfDiverse<
EnsureRoot<AccountId>,
pallet_collective::EnsureProportionAtLeast<AccountId, TechnicalCommitteeCollectiveInst, 1, 1>,
>;
pub type EnsureRootOrTwoThirdsTechnicalCommittee = EitherOfDiverse<
EnsureRoot<AccountId>,
pallet_collective::EnsureProportionAtLeast<AccountId, TechnicalCommitteeCollectiveInst, 2, 3>,
>;
pub type EnsureRootOrHalfTechnicalCommittee = EitherOfDiverse<
EnsureRoot<AccountId>,
pallet_collective::EnsureProportionAtLeast<AccountId, TechnicalCommitteeCollectiveInst, 1, 2>,
>;
pub type EnsureRootOrAllCommunityCouncil = EitherOfDiverse<
EnsureRoot<AccountId>,
pallet_collective::EnsureProportionAtLeast<AccountId, CommunityCouncilCollectiveInst, 1, 1>,
>;
pub type EnsureRootOrTwoThirdsCommunityCouncil = EitherOfDiverse<
EnsureRoot<AccountId>,
pallet_collective::EnsureProportionAtLeast<AccountId, CommunityCouncilCollectiveInst, 2, 3>,
>;
pub type EnsureRootOrHalfCommunityCouncil = EitherOfDiverse<
EnsureRoot<AccountId>,
pallet_collective::EnsureProportionAtLeast<AccountId, CommunityCouncilCollectiveInst, 1, 2>,
>;
pub type EnsureRootOrFourFifthsCommunityCouncil = EitherOfDiverse<
EnsureRoot<AccountId>,
pallet_collective::EnsureProportionAtLeast<AccountId, CommunityCouncilCollectiveInst, 4, 5>,
>;