Skip to content

Commit

Permalink
increase sent HKO & release payroll the next time
Browse files Browse the repository at this point in the history
Signed-off-by: Cheng JIANG <[email protected]>
  • Loading branch information
GopherJ committed Apr 9, 2022
1 parent bf6e10a commit 9e3877f
Show file tree
Hide file tree
Showing 2 changed files with 30 additions and 31 deletions.
33 changes: 16 additions & 17 deletions runtime/heiko/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -96,7 +96,7 @@ pub use pallet_bridge;
pub use pallet_farming;
pub use pallet_liquid_staking;
pub use pallet_loans;
pub use pallet_payroll;
// pub use pallet_payroll;
pub use pallet_prices;
pub use pallet_router;

Expand Down Expand Up @@ -272,9 +272,8 @@ impl Contains<Call> for BaseCallFilter {
// Bridge
Call::Bridge(_) |
// Farming
Call::Farming(_) |
// Payroll
Call::Payroll(_)
Call::Farming(_) // Payroll
// Call::Payroll(_)
)

// // Consensus
Expand Down Expand Up @@ -1059,7 +1058,7 @@ impl BalanceConversion<Balance, CurrencyId, Balance> for GiftConvert {
return Ok(Zero::zero());
}

let default_gift_amount = DOLLARS / 40; // 0.025HKO
let default_gift_amount = DOLLARS / 20; // 0.05HKO
Ok(match asset_id {
KSM if balance >= 10_u128.pow((decimal - 1).into()) => default_gift_amount,
EUSDT | EUSDC if balance >= 300 * 10_u128.pow(decimal.into()) => default_gift_amount,
Expand Down Expand Up @@ -1751,17 +1750,17 @@ impl pallet_crowdloans::Config for Runtime {
type Members = CrowdloansAutomatorsMembership;
}

parameter_types! {
pub const PayrollPalletId: PalletId = PalletId(*b"par/payr");
}

impl pallet_payroll::Config for Runtime {
type Event = Event;
type Assets = CurrencyAdapter;
type PalletId = PayrollPalletId;
type UnixTime = Timestamp;
type WeightInfo = pallet_payroll::weights::SubstrateWeight<Runtime>;
}
// parameter_types! {
// pub const PayrollPalletId: PalletId = PalletId(*b"par/payr");
// }
//
// impl pallet_payroll::Config for Runtime {
// type Event = Event;
// type Assets = CurrencyAdapter;
// type PalletId = PayrollPalletId;
// type UnixTime = Timestamp;
// type WeightInfo = pallet_payroll::weights::SubstrateWeight<Runtime>;
// }

parameter_types! {
pub const XcmHelperPalletId: PalletId = PalletId(*b"par/fees");
Expand Down Expand Up @@ -1962,7 +1961,7 @@ construct_runtime!(
EmergencyShutdown: pallet_emergency_shutdown::{Pallet, Call, Storage, Event<T>} = 91,
Farming: pallet_farming::{Pallet, Call, Storage, Event<T>} = 92,
XcmHelper: pallet_xcm_helper::{Pallet, Call, Storage, Event<T>} = 93,
Payroll: pallet_payroll::{Pallet, Call, Storage, Event<T>} = 94,
// Payroll: pallet_payroll::{Pallet, Call, Storage, Event<T>} = 94,

// Parachain System, always put it at the end
ParachainSystem: cumulus_pallet_parachain_system::{Pallet, Call, Config, Storage, Inherent, Event<T>, ValidateUnsigned} = 20,
Expand Down
28 changes: 14 additions & 14 deletions runtime/parallel/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -91,7 +91,7 @@ pub use pallet_bridge;
pub use pallet_farming;
pub use pallet_liquid_staking;
pub use pallet_loans;
pub use pallet_payroll;
// pub use pallet_payroll;
pub use pallet_prices;
pub use pallet_router;

Expand Down Expand Up @@ -245,7 +245,7 @@ impl Contains<Call> for BaseCallFilter {
Call::AMM(_) |
Call::AMMRoute(_) |
// Payroll
Call::Payroll(_) |
// Call::Payroll(_) |
// Farming
Call::Farming(_)
)
Expand Down Expand Up @@ -1691,17 +1691,17 @@ impl pallet_crowdloans::Config for Runtime {
type Members = CrowdloansAutomatorsMembership;
}

parameter_types! {
pub const PayrollPalletId: PalletId = PalletId(*b"par/payr");
}

impl pallet_payroll::Config for Runtime {
type Event = Event;
type Assets = CurrencyAdapter;
type PalletId = PayrollPalletId;
type UnixTime = Timestamp;
type WeightInfo = pallet_payroll::weights::SubstrateWeight<Runtime>;
}
// parameter_types! {
// pub const PayrollPalletId: PalletId = PalletId(*b"par/payr");
// }
//
// impl pallet_payroll::Config for Runtime {
// type Event = Event;
// type Assets = CurrencyAdapter;
// type PalletId = PayrollPalletId;
// type UnixTime = Timestamp;
// type WeightInfo = pallet_payroll::weights::SubstrateWeight<Runtime>;
// }

parameter_types! {
pub const XcmHelperPalletId: PalletId = PalletId(*b"par/fees");
Expand Down Expand Up @@ -1884,7 +1884,7 @@ construct_runtime!(
EmergencyShutdown: pallet_emergency_shutdown::{Pallet, Call, Storage, Event<T>} = 91,
Farming: pallet_farming::{Pallet, Call, Storage, Event<T>} = 92,
XcmHelper: pallet_xcm_helper::{Pallet, Call, Storage, Event<T>} = 93,
Payroll: pallet_payroll::{Pallet, Call, Storage, Event<T>} = 94,
// Payroll: pallet_payroll::{Pallet, Call, Storage, Event<T>} = 94,

// Parachain System, always put it at the end
ParachainSystem: cumulus_pallet_parachain_system::{Pallet, Call, Config, Storage, Inherent, Event<T>, ValidateUnsigned} = 20,
Expand Down

0 comments on commit 9e3877f

Please sign in to comment.