Crate pallet_payments
source · [−]Expand description
Payments Pallet
The Payments pallet supports the instantiation of lump sum or scheduled, iterative payments. Payments can come out of an individual’s account, or out of an escrow account set up by the payer of the payment agreement Payments must be claimed by individuals In the case of scheduled, iterative payments, payments can only be claimed if the claim comes after the scheduled payment date Inspiration for the source code of this pallet comes from the Pure-Stake Crowdloan Rewards Pallet: https://github.com/PureStake/crowdloan-rewards/blob/main/src/lib.rs
While the Crowdloan Rewards Pallet supports claiming rewards, this Payments Pallet supports the instantiation of scheduled payments as well as lump sum, one-time payments
Overview
The Payments pallet provides functions for:
- Setting up payments
- Claiming payments
- Blocking/Releasing payments from being claimed
Interface
Dispatchable Functions
initialize_payment
- Creates the payment details and commits them to storageclaim
- Transfers the next available funds to the payee’s accountblock_next_payment
- Prevent the claiming of the next and all subsequent paymentsrelease_next_payment
- Free up the next available and all subsequent payments for claiming
Re-exports
pub use pallet::*;