robor-systems / agoric-card-store

Dapp for NFT card store
2 stars 0 forks source link

Agoric card store dapp #2

Closed usamacs95 closed 2 years ago

usamacs95 commented 2 years ago

Description

Modify Agoric’s dapp-card-store to allow users to list their own cards for sale. Make the following modifications to the UI:

User should be able to list their card for sale. User flow:

  1. User navigates to “My Cards” page
  2. User selects a card to list for sale
  3. User chooses the sale mechanism (currently only one - Fixed price sale)
  4. Choose price for listing in RUN
  5. Optional for user: Choose end date & time for the listing
  6. User confirms choice and creates listing
  7. User navigates to “Marketplace” page and can see all marketplace listings and filter to his/her own listing(s)

Context

Agoric has an example dapp which allows users to purchase Baseball card NFTs directly from the application for a fixed price. The dapp instantiates a separate contract to sell these items and includes a basic front end.

For this project, we’d like you to extend the Dapp card store to allow holders of baseball cards to offer theirs for sale at a fixed price.

Current Implementation:

https://github.com/Agoric/dapp-card-store

Additional Notes

aamnasarosh commented 2 years ago

Agoric Dapp Design - Dev link: https://xd.adobe.com/view/d825c6e4-887c-4432-9c98-5fce91a25cb2-8d76/

haseebasim commented 2 years ago

Update 17 December 2021

Hussain-7 commented 2 years ago

Update 17th December 2021

haseebasim commented 2 years ago

Update 20th Dec

haseebasim commented 2 years ago

Update 21st Dec

haseebasim commented 2 years ago

Update 22nd Dec

haseebasim commented 2 years ago

Update 23rd Dec

haseebasim commented 2 years ago

Update 24 Dec

danishyasin33 commented 2 years ago

TODO:

danishyasin33 commented 2 years ago

Moreover, today research on agoric card store API and learn how they store the player names. The question that needs to be answered:

Basically help me understand how the existing contract and it's API works and how will we implement a full scale marketplace through it.

Read up on Agoric documentation to familiarize yourself with how their smart contract works because we'll be drilling down deeply into their framework for this task.

I will catch up with you later tonight.

haseebasim commented 2 years ago

Update 29th December

haseebasim commented 2 years ago

Update 30th December

haseebasim commented 2 years ago

Update 31st December 2021

Tried modifying the card store dapp API to send the meta in the form of a name and a URI but was unsuccessful.

haseebasim commented 2 years ago

Update 4th Jan 2022

haseebasim commented 2 years ago

Modification required for the current card-store-dapp

haseebasim commented 2 years ago

Update 15th January 2022

haseebasim commented 2 years ago

Update 16th January 2022

danishyasin33 commented 2 years ago

Your tasks @haseebasim

Your tasks @Hussain-7:

haseebasim commented 2 years ago

Update 17th January, 2022

Hussain-7 commented 2 years ago

Update 17th January 2022

Hussain-7 commented 2 years ago

Update 18th January 2022

haseebasim commented 2 years ago

Update 18th January 2022

Future Todos

Hussain-7 commented 2 years ago

Update 19th January 2022

RoadMap to completion:

1) Show current user's nfts on the My Cards page

haseebasim commented 2 years ago

Update 19 January, 2022

Future Todos

danishyasin33 commented 2 years ago

Questions to be answered:

danishyasin33 commented 2 years ago
danishyasin33 commented 2 years ago

@haseebasim your task:

Acceptance Criteria:

Flow to parse ipfs

haseebasim commented 2 years ago

Update 20th January, 2022

Hussain-7 commented 2 years ago

Update 20th January 2022

Hussain-7 commented 2 years ago

Update 21st January 2022

haseebasim commented 2 years ago

Update 21st January 2022

danishyasin33 commented 2 years ago

@haseebasim store the whole json string of the meta data in the contract instead of just the ipfs hash. We will retrieve this string in the UI and parse the image IPFS hash from it. This will also need an attribute by the name of id, which has to be unique and will be used for tracking offers as pointed out by @Hussain-7. These ids can be created via nanoid

Hussain-7 commented 2 years ago

Update 24th January 2022

haseebasim commented 2 years ago

Update 24th January 2022

danishyasin33 commented 2 years ago
  • For that we needed the same minter, issuer and brand from the main card minting contract to create a payment.

For what purpose do we require minter and issuer? We cannot create new asset types on the front end. Whenever a new asset needs to be minted, this should be handled through the contract methods.

Hussain-7 commented 2 years ago
  • For that we needed the same minter, issuer and brand from the main card minting contract to create a payment.

For what purpose do we require minter and issuer? We cannot create new asset types on the front end. Whenever a new asset needs to be minted, this should be handled through the contract methods.

haseebasim commented 2 years ago

Update 25th January 2022


Todos:

The Flow of the Secondary Market Place

Hussain-7 commented 2 years ago

Update 25th January 2022

Current Progress:

danishyasin33 commented 2 years ago

Questions:

danishyasin33 commented 2 years ago

Summary of the Agoric NFT card store

The old NFT marketplace already had the functionality of the primary marketplace. It is kept as is for now and we have not made changes to that contract.

To add in the functionality of the secondary marketplace where users can place their items on sale and carry out transactions with each other, we have created a new smart contract called secondaryStore.

The new contract is based off of the atomicSwap contract. This is because we required the swap functionality already being employed in this contract. Now I am going to explain how we are achieving the main functionalities of the secondary marketplace:

Selling an NFT

@rowgraus

haseebasim commented 2 years ago

Update 26th January 2022


Hussain-7 commented 2 years ago

Update 26th January 2022

Progress

Hussain-7 commented 2 years ago

Update 27th January 2022

Progress:

Hussain-7 commented 2 years ago

Update 28th January 2022

Progress:

danishyasin33 commented 2 years ago

Gracefully handle error when contract is not deployed: image

danishyasin33 commented 2 years ago

Please add url parameters according to tabs to make it easier to open to a specific tab: image

danishyasin33 commented 2 years ago

Note:

danishyasin33 commented 2 years ago

@haseebasim please fix the designing of the marketplace, the cards are not stackable and are not responsive. Please check for design inconsistencies throughout the dapp:

image

danishyasin33 commented 2 years ago

@Hussain-7 please add comments in contracts and api code, explain the thought process behind each variable. Also write tests for all the contracts.

Comments should match the following patterns: // CMT (hussain@robor.systems): comment text

@haseebasim please take note as well and do the same for minting contract

Hussain-7 commented 2 years ago

@haseebasim please complete the following task. Before moving to any next task. These were some of the issues @danishyasin33 pointed out during the code review.

todos: