| Maintainer | emi@haskell.fyi |
|---|---|
| Safe Haskell | Safe-Inferred |
| Language | Haskell2010 |
Agora.Proposal.Scripts
Description
Plutus Scripts for Proposals.
Synopsis
Documentation
proposalValidator :: Proposal -> ClosedTerm PValidator Source #
The validator for Proposals.
The documentation for various of the redeemers lives at ProposalRedeemer.
What this validator does
Voting/unlocking
When voting and unlocking, the proposal must witness a state transition
occuring in the relevant Stake. This transition must place a lock on
the stake that is tagged with the right ResultTag, and ProposalId.
Periods
Most redeemers are time-sensitive.
A list of all time-sensitive redeemers and their requirements:
Votecan only be used when both the status is inVotingReady, andisVotingPeriodis true.Cosigncan only be used when both the status is inDraft, andisDraftPeriodis true.AdvanceProposalcan only be used when the status can be advanced (seeAdvanceProposaldocs).Unlockis always valid.
Since: 0.1.0
Arguments
| :: AssetClass | The assetclass of GST, see |
| -> ClosedTerm PMintingPolicy |
Policy for Proposals.
What this policy does
For minting:
- Governor is happy with mint.
- The governor must do most of the checking for the validity of the transaction. For example, the governor must check that the datum is correct, and that the ST is correctly paid to the right validator.
- Exactly 1 token is minted.
For burning:
- This policy cannot be burned.
Since: 0.1.0