@@ -2451,7 +2451,7 @@ mod dispatches {
2451
2451
) -> DispatchResult {
2452
2452
let account_id = crate :: ensure_evm_origin ( <T as Config >:: RuntimeOrigin :: from ( origin) ) ?;
2453
2453
let verified_evm_origin = RawOrigin :: Signed ( account_id) ;
2454
-
2454
+
2455
2455
Self :: do_move_stake (
2456
2456
verified_evm_origin. into ( ) ,
2457
2457
origin_hotkey,
@@ -2477,7 +2477,7 @@ mod dispatches {
2477
2477
) -> DispatchResult {
2478
2478
let account_id = crate :: ensure_evm_origin ( <T as Config >:: RuntimeOrigin :: from ( origin) ) ?;
2479
2479
let verified_evm_origin = RawOrigin :: Signed ( account_id) ;
2480
-
2480
+
2481
2481
Self :: do_transfer_stake (
2482
2482
verified_evm_origin. into ( ) ,
2483
2483
destination_coldkey,
@@ -2488,32 +2488,21 @@ mod dispatches {
2488
2488
)
2489
2489
}
2490
2490
2491
- /// swap_stake with EVM origin
2491
+ /// remove_stake_full_limit with EVM origin
2492
2492
#[ pallet:: call_index( 129 ) ]
2493
- #[ pallet:: weight( (
2494
- Weight :: from_parts( 351_300_000 , 0 )
2495
- . saturating_add( T :: DbWeight :: get( ) . reads( 32 ) )
2496
- . saturating_add( T :: DbWeight :: get( ) . writes( 17 ) ) ,
2497
- DispatchClass :: Operational ,
2498
- Pays :: Yes
2499
- ) ) ]
2500
- pub fn swap_stake (
2493
+ #[ pallet:: weight( ( Weight :: from_parts( 398_000_000 , 10142 )
2494
+ . saturating_add( T :: DbWeight :: get( ) . reads( 30_u64 ) )
2495
+ . saturating_add( T :: DbWeight :: get( ) . writes( 14_u64 ) ) , DispatchClass :: Normal , Pays :: Yes ) ) ]
2496
+ pub fn remove_stake_full_limit_evm (
2501
2497
origin : OriginFor < T > ,
2502
2498
hotkey : T :: AccountId ,
2503
- origin_netuid : NetUid ,
2504
- destination_netuid : NetUid ,
2505
- alpha_amount : AlphaCurrency ,
2499
+ netuid : NetUid ,
2500
+ limit_price : Option < u64 > ,
2506
2501
) -> DispatchResult {
2507
2502
let account_id = crate :: ensure_evm_origin ( <T as Config >:: RuntimeOrigin :: from ( origin) ) ?;
2508
2503
let verified_evm_origin = RawOrigin :: Signed ( account_id) ;
2509
-
2510
- Self :: do_swap_stake (
2511
- verified_evm_origin. into ( ) ,
2512
- hotkey,
2513
- origin_netuid,
2514
- destination_netuid,
2515
- alpha_amount,
2516
- )
2504
+
2505
+ Self :: do_remove_stake_full_limit ( verified_evm_origin. into ( ) , hotkey, netuid, limit_price)
2517
2506
}
2518
2507
}
2519
2508
}
0 commit comments