mirror of
https://github.com/FiloSpaTeam/plutus-pioneer-program.git
synced 2024-12-25 01:11:59 +01:00
small changes
This commit is contained in:
parent
61529e1b5f
commit
a024fb915c
2 changed files with 42 additions and 3 deletions
|
@ -46,7 +46,7 @@
|
|||
- [`Plutus.V1.Ledger.Interval`](https://github.com/input-output-hk/plutus/blob/master/plutus-ledger-api/src/Plutus/V1/Ledger/Interval.hs), contains the definition of and helper functions for the `Interval` type.
|
||||
- [`Plutus.V1.Ledger.Slot`](https://github.com/input-output-hk/plutus/blob/master/plutus-ledger-api/src/Plutus/V1/Ledger/Slot.hs), contains the definition of the `Slot` type.
|
||||
- [`Plutus.V1.Ledger.Value`](https://github.com/input-output-hk/plutus/blob/master/plutus-ledger-api/src/Plutus/V1/Ledger/Value.hs), contains the definition of and helper functions for the `Value` type.
|
||||
- [`PlutusTx.Data`](https://github.com/input-output-hk/plutus/blob/master/plutus-tx/src/PlutusTx/Data.hs), contains the definition of the `Data` type.
|
||||
- [`PlutusTx.Builtins.Data`](https://github.com/input-output-hk/plutus/blob/master/plutus-core/plutus-core/src/PlutusCore/Data.hs), contains the definition of the `Data` type.
|
||||
- [`PlutusTx.IsData.Class`](https://github.com/input-output-hk/plutus/blob/master/plutus-tx/src/PlutusTx/IsData/Class.hs), defines the `IsData` class.
|
||||
|
||||
## Additional Resources
|
||||
|
|
|
@ -24,8 +24,6 @@ import Ledger.Ada as Ada
|
|||
import Playground.Contract (printJson, printSchemas, ensureKnownCurrencies, stage)
|
||||
import Playground.TH (mkKnownCurrencies, mkSchemaDefinitions)
|
||||
import Playground.Types (KnownCurrency (..))
|
||||
import Prelude (Semigroup (..), String)
|
||||
import Text.Printf (printf)
|
||||
|
||||
{-# OPTIONS_GHC -fno-warn-unused-imports #-}
|
||||
|
||||
|
@ -42,6 +40,46 @@ valHash = Scripts.validatorHash validator
|
|||
scrAddress :: Ledger.Address
|
||||
scrAddress = scriptAddress validator
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
{-
|
||||
{-# INLINABLE mkValidator #-}
|
||||
mkValidator :: Data -> Data -> Data -> ()
|
||||
mkValidator _ _ _ = ()
|
||||
|
||||
validator :: Validator
|
||||
validator = mkValidatorScript $$(PlutusTx.compile [|| mkValidator ||])
|
||||
|
||||
type GiftSchema =
|
||||
Endpoint "give" Integer
|
||||
.\/ Endpoint "grab" ()
|
||||
|
@ -74,3 +112,4 @@ endpoints = (give' `select` grab') >> endpoints
|
|||
mkSchemaDefinitions ''GiftSchema
|
||||
|
||||
mkKnownCurrencies []
|
||||
-}
|
||||
|
|
Loading…
Reference in a new issue