Skip to content

Commit

Permalink
Adds V3 Market Contract and transactions (#118)
Browse files Browse the repository at this point in the history
* updates transactions and tests for v3

* PR comments

* remove bug lines and fix PR comments

* Sadie/market v3 review comments (#120)

* update comment - remove exceeds

* remove change percentage

* remove change percentage

* add test back in

* upgrade go -> 1.16

* go -> 1.16

* update go version for ci

* update go sum

Co-authored-by: Sadie Freeman <[email protected]>
  • Loading branch information
joshuahannan and sadief authored Jul 14, 2021
1 parent 9e76cff commit 31697fb
Show file tree
Hide file tree
Showing 40 changed files with 1,355 additions and 523 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,5 +9,5 @@ jobs:
- uses: actions/checkout@v2
- uses: actions/setup-go@v1
with:
go-version: '1.13.10'
go-version: '1.16'
- run: make ci
8 changes: 5 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -363,7 +363,9 @@ and if they sent the correct amount, they get the Moment back.
There are two versions of the Top Shot Market Contract.
`TopShotMarket.cdc` is the original version of the contract that was used
for the first set of sales in the p2p marketplace, but we made improvements
to it which are now in `TopShotMarketV2.cdc`.
to it which are now in `TopShotMarketV3.cdc`.

There is also a V2 version that was deployed to mainnet, but will never be used.

Both versions define a `SaleCollection` resource that users store in their account.
The resource manages the logic of the sale like listings, de-listing, prices, and
Expand All @@ -376,15 +378,15 @@ put up for sale. In this version, when a moment is purchased, the sale collectio
uses the capability to withdraw the moment from the main collection and
returns it to the buyer.

The second version of the market contract is currently NOT DEPLOYED to mainnet,
The new version of the market contract is currently NOT DEPLOYED to mainnet,
but it will be deployed and utilized in the near future.

## License

The works in these folders
/dapperlabs/nba-smart-contracts/blob/master/contracts/TopShot.cdc
/dapperlabs/nba-smart-contracts/blob/master/contracts/MarketTopShot.cdc
/dapperlabs/nba-smart-contracts/blob/master/contracts/MarketTopShotV2.cdc
/dapperlabs/nba-smart-contracts/blob/master/contracts/MarketTopShotV3.cdc
/dapperlabs/nba-smart-contracts/blob/master/contracts/TopShotAdminReceiver.cdc
/dapperlabs/nba-smart-contracts/blob/master/contracts/TopShotShardedCollection.cdc

Expand Down
3 changes: 0 additions & 3 deletions contracts/MarketTopShot.cdc
Original file line number Diff line number Diff line change
Expand Up @@ -4,9 +4,6 @@
Description: Contract definitions for users to sell their moments
Authors: Joshua Hannan [email protected]
Dieter Shirley [email protected]
Marketplace is where users can create a sale collection that they
store in their account storage. In the sale collection,
they can put their NFTs up for sale with a price and publish a
Expand Down
3 changes: 0 additions & 3 deletions contracts/TopShot.cdc
Original file line number Diff line number Diff line change
@@ -1,9 +1,6 @@
/*
Description: Central Smart Contract for NBA TopShot
authors: Joshua Hannan [email protected]
Dieter Shirley [email protected]
This smart contract contains the core functionality for
NBA Top Shot, created by Dapper Labs
Expand Down
3 changes: 0 additions & 3 deletions contracts/TopShotMarketV2.cdc
Original file line number Diff line number Diff line change
Expand Up @@ -4,9 +4,6 @@
Description: Contract definitions for users to sell their moments
Authors: Joshua Hannan [email protected]
Dieter Shirley [email protected]
Marketplace is where users can create a sale collection that they
store in their account storage. In the sale collection,
they can put their NFTs up for sale with a price and publish a
Expand Down
Loading

0 comments on commit 31697fb

Please sign in to comment.