Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Motivation
Writing the first Marketplace contract for Aptos. This is based on the TODO item of this issue.
The implementation is based on TokenTransfers.move.
The flow is:
The only rule of the marketplace is that the buyer cannot be the seller.
When a token is listed for sale, the token is escrowed to the market owner account. When a buyer buys the token, the token is claimed by the buyer and removed from escrow from the owner account.
(Write your motivation for proposed changes here.)
Have you read the Contributing Guidelines on pull requests?
Yes
(You must have submitted a signed CLA that includes your GitHub handle prior to us accepting and landing your work. Write your answer here.)
Test Plan
Added a test for the move module as the function (list_buy_test).
Also, tested the script by publishing it and testing the functions.