diff --git a/resources/js/components/marketplace/CounterOffersList.vue b/resources/js/components/marketplace/CounterOffersList.vue new file mode 100644 index 00000000..186a12b1 --- /dev/null +++ b/resources/js/components/marketplace/CounterOffersList.vue @@ -0,0 +1,359 @@ + + + diff --git a/resources/js/components/marketplace/OffersList.vue b/resources/js/components/marketplace/OffersList.vue new file mode 100644 index 00000000..7ff35833 --- /dev/null +++ b/resources/js/components/marketplace/OffersList.vue @@ -0,0 +1,359 @@ + + + diff --git a/resources/js/components/pages/create/CreateListing.vue b/resources/js/components/pages/create/CreateListing.vue index 1f3d91c0..4fb72b85 100644 --- a/resources/js/components/pages/create/CreateListing.vue +++ b/resources/js/components/pages/create/CreateListing.vue @@ -281,12 +281,15 @@ const createListing = async () => { collectionId: takeCollectionId.value, tokenId: formatToken(takeTokenId.value), }, - auctionData: enableAuction.value - ? { - startBlock: auctionDataStart.value, - endBlock: auctionDataEnd.value, - } - : null, + listingData: { + type: enableAuction.value ? 'AUCTION' : 'FIXED_PRICE', + auctionParams: enableAuction.value + ? { + startBlock: auctionDataStart.value, + endBlock: auctionDataEnd.value, + } + : undefined, + }, idempotencyKey: idempotencyKey.value, }) ); diff --git a/resources/js/components/pages/create/CreateOffer.vue b/resources/js/components/pages/create/CreateOffer.vue new file mode 100644 index 00000000..7fb714ef --- /dev/null +++ b/resources/js/components/pages/create/CreateOffer.vue @@ -0,0 +1,259 @@ + + + diff --git a/resources/js/graphql/mutation/marketplace/CreateListing.ts b/resources/js/graphql/mutation/marketplace/CreateListing.ts index 10f64f22..ca71e6a8 100644 --- a/resources/js/graphql/mutation/marketplace/CreateListing.ts +++ b/resources/js/graphql/mutation/marketplace/CreateListing.ts @@ -1,11 +1,12 @@ -export default `mutation CreateListing($makeAssetId: MultiTokenIdInput!, $takeAssetId: MultiTokenIdInput!, $amount: BigInt!, $price: BigInt!, $salt: String, $auctionData: AuctionDataInputType, $idempotencyKey: String) { +export default `mutation CreateListing($makeAssetId: MultiTokenIdInput!, $takeAssetId: MultiTokenIdInput!, $amount: BigInt!, $price: BigInt!, $salt: String, $listingData: ListingDataInput, $signingAccount: String, $idempotencyKey: String) { CreateListing( makeAssetId: $makeAssetId takeAssetId: $takeAssetId amount: $amount price: $price salt: $salt - auctionData: $auctionData + listingData: $listingData + signingAccount: $signingAccount idempotencyKey: $idempotencyKey ) { id diff --git a/resources/js/router/index.ts b/resources/js/router/index.ts index a93f085a..e4004312 100644 --- a/resources/js/router/index.ts +++ b/resources/js/router/index.ts @@ -165,6 +165,15 @@ const routes = [ requiresToken: true, }, }, + { + path: '/create/offer', + name: 'platform.create.offer', + component: () => import('../components/pages/create/CreateOffer.vue'), + meta: { + requiresAuth: true, + requiresToken: true, + }, + }, { path: '/create/batch', name: 'platform.create.batch',