Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 5 additions & 0 deletions pallets/vsbond-auction/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,7 @@ use frame_support::{
traits::{AtLeast32BitUnsigned, SaturatedConversion, Saturating, Zero},
FixedPointNumber, FixedU128,
},
transactional,
};
use frame_system::pallet_prelude::*;
use node_primitives::{CurrencyId, LeasePeriod, ParaId, TokenSymbol};
Expand Down Expand Up @@ -225,6 +226,7 @@ pub mod pallet {
#[pallet::call]
impl<T: Config<I>, I: 'static> Pallet<T, I> {
/// Create a sell order or buy order to sell `vsbond`.
#[transactional]
#[pallet::weight(T::WeightInfo::create_order())]
pub fn create_order(
origin: OriginFor<T>,
Expand Down Expand Up @@ -303,6 +305,7 @@ pub mod pallet {
}

/// Revoke a sell or buy order in trade by the order creator.
#[transactional]
#[pallet::weight(T::WeightInfo::revoke_order())]
pub fn revoke_order(
origin: OriginFor<T>,
Expand Down Expand Up @@ -349,6 +352,7 @@ pub mod pallet {
}

/// Users(non-order-creator) buy the remaining `vsbond` of a sell order.
#[transactional]
#[pallet::weight(T::WeightInfo::clinch_order())]
pub fn clinch_order(
origin: OriginFor<T>,
Expand All @@ -362,6 +366,7 @@ pub mod pallet {
}

/// Users(non-order-creator) buys some of the remaining `vsbond` of a sell or buy order.
#[transactional]
#[pallet::weight(T::WeightInfo::partial_clinch_order())]
pub fn partial_clinch_order(
origin: OriginFor<T>,
Expand Down