mirror of
https://github.com/pezkuwichain/pezkuwi-subxt.git
synced 2026-04-26 20:27:58 +00:00
decl_module! macro: use 'frame_system' instead of system as default ident (#6500)
* Use frame_system as default ident. * Remove unused 'frame_system' to 'system' renaming. * Fix construct_runtime_ui tests. * Rename system to frame_system in sudo/utility pallet test. * Bump runtime impl_version. * Update formatting.
This commit is contained in:
@@ -35,8 +35,8 @@ pub mod logger {
|
||||
use super::*;
|
||||
use frame_system::ensure_root;
|
||||
|
||||
pub trait Trait: system::Trait {
|
||||
type Event: From<Event<Self>> + Into<<Self as system::Trait>::Event>;
|
||||
pub trait Trait: frame_system::Trait {
|
||||
type Event: From<Event<Self>> + Into<<Self as frame_system::Trait>::Event>;
|
||||
}
|
||||
|
||||
decl_storage! {
|
||||
@@ -54,7 +54,7 @@ pub mod logger {
|
||||
}
|
||||
|
||||
decl_module! {
|
||||
pub struct Module<T: Trait> for enum Call where origin: <T as system::Trait>::Origin {
|
||||
pub struct Module<T: Trait> for enum Call where origin: <T as frame_system::Trait>::Origin {
|
||||
fn deposit_event() = default;
|
||||
|
||||
#[weight = *weight]
|
||||
@@ -87,7 +87,7 @@ mod test_events {
|
||||
|
||||
impl_outer_event! {
|
||||
pub enum TestEvent for Test {
|
||||
system<T>,
|
||||
frame_system<T>,
|
||||
sudo<T>,
|
||||
logger<T>,
|
||||
}
|
||||
@@ -161,7 +161,7 @@ impl Trait for Test {
|
||||
// Assign back to type variables in order to make dispatched calls of these modules later.
|
||||
pub type Sudo = Module<Test>;
|
||||
pub type Logger = logger::Module<Test>;
|
||||
pub type System = system::Module<Test>;
|
||||
pub type System = frame_system::Module<Test>;
|
||||
|
||||
// New types for dispatchable functions.
|
||||
pub type SudoCall = sudo::Call<Test>;
|
||||
|
||||
Reference in New Issue
Block a user