Skip to content

Commit

Permalink
setup asset-rate on moonbase
Browse files Browse the repository at this point in the history
  • Loading branch information
pLabarta committed Feb 26, 2025
1 parent 5ddbb1f commit 5aec11e
Showing 1 changed file with 13 additions and 1 deletion.
14 changes: 13 additions & 1 deletion runtime/moonbase/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,7 @@ use frame_support::{
pallet_prelude::DispatchResult,
parameter_types,
traits::{
fungible::{Balanced, Credit, HoldConsideration, Inspect},
fungible::{Balanced, Credit, HoldConsideration, Inspect, NativeOrWithId},
tokens::{PayFromAccount, UnityAssetBalanceConversion},
ConstBool, ConstU128, ConstU16, ConstU32, ConstU64, ConstU8, Contains, EitherOf,
EitherOfDiverse, EqualPrivilegeOnly, FindAuthor, InstanceFilter, LinearStoragePrice,
Expand Down Expand Up @@ -557,6 +557,16 @@ impl pallet_preimage::Config for Runtime {
>;
}

impl pallet_asset_rate::Config for Runtime {
type RuntimeEvent = RuntimeEvent;
type WeightInfo = pallet_asset_rate::weights::SubstrateWeight<Runtime>;
type CreateOrigin = EnsureRoot<AccountId>;
type RemoveOrigin = EnsureRoot<AccountId>;
type UpdateOrigin = EnsureRoot<AccountId>;
type Currency = Balances;
type AssetKind = NativeOrWithId<u32>;
}

parameter_types! {
pub const ProposalBond: Permill = Permill::from_percent(5);
pub const TreasuryId: PalletId = PalletId(*b"pc/trsry");
Expand Down Expand Up @@ -1416,6 +1426,8 @@ construct_runtime! {
EvmForeignAssets: pallet_moonbeam_foreign_assets::{Pallet, Call, Storage, Event<T>} = 56,
Parameters: pallet_parameters = 57,
XcmWeightTrader: pallet_xcm_weight_trader::{Pallet, Call, Storage, Event<T>} = 58,
AssetRate: pallet_asset_rate::{Pallet, Call, Storage, Event<T>} = 59,

}
}

Expand Down

0 comments on commit 5aec11e

Please sign in to comment.