Merge branch 'master' into connor/governor
This commit is contained in:
commit
cbf14337ff
18 changed files with 1103 additions and 8 deletions
|
|
@ -11,6 +11,8 @@ module Agora.AuthorityToken (
|
|||
AuthorityToken (..),
|
||||
) where
|
||||
|
||||
--------------------------------------------------------------------------------
|
||||
|
||||
import Plutarch.Api.V1 (
|
||||
PAddress (..),
|
||||
PCredential (..),
|
||||
|
|
@ -28,7 +30,9 @@ import Plutarch.Api.V1.Value (PValue (PValue))
|
|||
import Plutarch.Builtin (pforgetData)
|
||||
import Plutus.V1.Ledger.Value (AssetClass (AssetClass))
|
||||
|
||||
import Prelude
|
||||
--------------------------------------------------------------------------------
|
||||
|
||||
import GHC.Generics qualified as GHC
|
||||
|
||||
--------------------------------------------------------------------------------
|
||||
|
||||
|
|
@ -53,6 +57,7 @@ newtype AuthorityToken = AuthorityToken
|
|||
{ authority :: AssetClass
|
||||
-- ^ Token that must move in order for minting this to be valid.
|
||||
}
|
||||
deriving stock (GHC.Generic)
|
||||
|
||||
--------------------------------------------------------------------------------
|
||||
|
||||
|
|
|
|||
|
|
@ -106,6 +106,7 @@ data Governor = Governor
|
|||
-- ^ Arbitrary limit for maximum amount of cosigners on a proposal.
|
||||
-- See `Agora.Proposal.proposalDatumValid`.
|
||||
}
|
||||
deriving stock (GHC.Generic)
|
||||
|
||||
--------------------------------------------------------------------------------
|
||||
|
||||
|
|
|
|||
|
|
@ -81,7 +81,7 @@ newtype ProposalId = ProposalId {proposalTag :: Integer}
|
|||
@
|
||||
-}
|
||||
newtype ResultTag = ResultTag {getResultTag :: Integer}
|
||||
deriving stock (Eq, Show, Ord)
|
||||
deriving stock (Eq, Show, Ord, GHC.Generic)
|
||||
deriving newtype (PlutusTx.ToData, PlutusTx.FromData, PlutusTx.UnsafeFromData)
|
||||
|
||||
{- | The "status" of the proposal. This is only useful for state transitions that
|
||||
|
|
@ -246,7 +246,7 @@ data Proposal = Proposal
|
|||
, maximumCosigners :: Integer
|
||||
-- ^ Arbitrary limit for maximum amount of cosigners on a proposal.
|
||||
}
|
||||
deriving stock (Show, Eq)
|
||||
deriving stock (Show, Eq, GHC.Generic)
|
||||
|
||||
--------------------------------------------------------------------------------
|
||||
-- Plutarch-land
|
||||
|
|
|
|||
|
|
@ -82,6 +82,7 @@ data Stake = Stake
|
|||
-- ^ Used when inlining the AssetClass of a 'PDiscrete' in the script code.
|
||||
, proposalSTClass :: AssetClass
|
||||
}
|
||||
deriving stock (GHC.Generic)
|
||||
|
||||
{- | A lock placed on a Stake datum in order to prevent
|
||||
depositing and withdrawing when votes are in place.
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue