diff --git a/src/components/market/ChipBuyDialog.vue b/src/components/market/ChipBuyDialog.vue index 5bb80df..1f7d70c 100644 --- a/src/components/market/ChipBuyDialog.vue +++ b/src/components/market/ChipBuyDialog.vue @@ -167,11 +167,6 @@ export default { this.$emit("handBuyHide", false); }, async handBeginBuy() { - const data = { - o_link: this.piece.o_link ? this.piece.o_link : this.data.o_link, - marketDddress: CONTRACT_ADDRESS[AppModule.chainId].marketDddress, - }; - console.log(data, "data"); try { this.showLoading(); const nftres = await this.chainManager.bc.beginBuy( @@ -181,7 +176,6 @@ export default { if (nftres.status == true) { this.hideLoading(); this.$emit("handMessage", 1); - // this.closeTip() if(this.type == "chip"){ setTimeout(() => { this.$emit("handMessageHide"); @@ -202,7 +196,6 @@ export default { }, 1000); } } - console.log(nftres, "beginBuy"); } catch (err) { this.hideLoading(); this.$emit("handMessage", 0); diff --git a/src/components/market/Chipdialog.vue b/src/components/market/Chipdialog.vue index ae834e5..3bf894b 100644 --- a/src/components/market/Chipdialog.vue +++ b/src/components/market/Chipdialog.vue @@ -194,17 +194,13 @@ export default { return getChipArrid(nameId); }, async handRemove() { - console.log( - this.data.o_link, - CONTRACT_ADDRESS[AppModule.chainId].marketDddress - ); + try { this.showLoading() const nftres = await this.chainManager.bc.beginCancelOrder( this.data.o_link, CONTRACT_ADDRESS[AppModule.chainId].marketDddress ); - console.log(nftres, "beginSell"); if (nftres.status == true) { this.$emit("handMessage", 1); this.hideLoading(); diff --git a/src/components/market/HeroBuyDialog.vue b/src/components/market/HeroBuyDialog.vue index 48ec449..bada765 100644 --- a/src/components/market/HeroBuyDialog.vue +++ b/src/components/market/HeroBuyDialog.vue @@ -78,11 +78,7 @@ export default { }, methods: { async haldBuy() { - const data = { - currency: this.data.s_currency, - price: this.data.s_price, - marketDddress: CONTRACT_ADDRESS[AppModule.chainId].marketDddress, - }; + try { this.showLoading(); const nftres = await this.chainManager.bc.beginApproveBuy( @@ -103,18 +99,13 @@ export default { } }, async handBeginBuy() { - const data = { - o_link: this.data.o_link, - marketDddress: CONTRACT_ADDRESS[AppModule.chainId].marketDddress, - }; - console.log(data, "data"); + try { this.showLoading(); const nftres = await this.chainManager.bc.beginBuy( this.data.o_link, CONTRACT_ADDRESS[AppModule.chainId].marketDddress ); - console.log(nftres, "beginSell"); if (nftres.status == true) { this.hideLoading(); this.$emit("handMessage", 1); @@ -147,7 +138,7 @@ export default { }, closeTip() { this.$emit("handBuyHide"); - console.log("closeTip"); + }, }, }; diff --git a/src/components/market/HeroBuyTop.vue b/src/components/market/HeroBuyTop.vue index 134a94b..10e0352 100644 --- a/src/components/market/HeroBuyTop.vue +++ b/src/components/market/HeroBuyTop.vue @@ -103,12 +103,10 @@ export default { margin-top: 22px; position: relative; line-height: 63px; - // text-align: center; background: url("../../assets/market/hero/price.png") no-repeat; background-size: 100% 100%; .priece-number { position: absolute; - // left: 55px; right: 7px; top: 2px; } diff --git a/src/components/market/Herodialog.vue b/src/components/market/Herodialog.vue index a9ab0b8..e733cc5 100644 --- a/src/components/market/Herodialog.vue +++ b/src/components/market/Herodialog.vue @@ -410,7 +410,6 @@ export default { this.hero.o_link, CONTRACT_ADDRESS[AppModule.chainId].marketDddress ); - console.log(nftres, "beginSell"); if (nftres.status == true) { this.$emit("handMessage", 1); this.hideLoading(); diff --git a/src/components/market/NftTypeBar.vue b/src/components/market/NftTypeBar.vue index f342ee1..65ca308 100644 --- a/src/components/market/NftTypeBar.vue +++ b/src/components/market/NftTypeBar.vue @@ -8,7 +8,6 @@ :class="{ active: selectIdx - 1 === i }" @click="onClickItem(i)" > - diff --git a/src/components/market/PieceSellTop.vue b/src/components/market/PieceSellTop.vue index 2567d69..a02eede 100644 --- a/src/components/market/PieceSellTop.vue +++ b/src/components/market/PieceSellTop.vue @@ -32,9 +32,15 @@
Amount
-
+
{{ cunout }}
-
+
Max
@@ -72,9 +78,9 @@ export default { handPlus() { this.$emit("handPlus"); }, - handMax(){ + handMax() { this.$emit("handMax"); - } + }, }, }; @@ -166,10 +172,18 @@ export default { width: 30px; cursor: pointer; } + .left-active { + width: 30px; + cursor: not-allowed; + } .right { width: 30px; cursor: pointer; } + .right-active { + width: 30px; + cursor: not-allowed; + } .conunt-number { width: 56px; line-height: 27px; diff --git a/src/components/market/TheSellDialog.vue b/src/components/market/TheSellDialog.vue index 2cb8946..ea34e3b 100644 --- a/src/components/market/TheSellDialog.vue +++ b/src/components/market/TheSellDialog.vue @@ -163,7 +163,6 @@ export default { async handConfirm() { this.$refs.deptForm.validate(async (valid) => { if (valid) { - console.log(this.piece.o_link, "o_link"); if ( this.type == "piece" ? this.piece.o_link > 0 : this.data.o_link > 0 ) { @@ -174,7 +173,6 @@ export default { this.shell.price, CONTRACT_ADDRESS[AppModule.chainId].marketDddress ); - console.log(nftres, "beginSell"); if (nftres.status == true) { this.hideLoading(); this.$emit("handMessage", 1); @@ -209,16 +207,7 @@ export default { this.nft_Token = CONTRACT_ADDRESS[AppModule.chainId].piece; break; } - const data = { - tokenId: this.piece - ? this.piece.detail.token_id - : this.data.detail.token_id, - nftToken: this.nft_Token, - nftType: - this.type == "hero" || this.type == "weapon" ? false : true, - marketAddress: CONTRACT_ADDRESS[AppModule.chainId].marketDddress, - }; - console.log(data, "dataap"); + try { this.showLoading(); const nftres = await this.chainManager.bc.beginApproveSell( @@ -229,19 +218,16 @@ export default { this.type == "hero" || this.type == "weapon" ? false : true, CONTRACT_ADDRESS[AppModule.chainId].marketDddress ); - console.log(nftres, "beginApproveSell"); if (nftres.status == true) { this.isApprove = true; this.hideLoading(); - // this.$emit("handMessage", 1); - this.handBeginNftSell(); } } catch (err) { this.hideLoading(); this.isApprove = false; this.$emit("handMessage", 0); - console.log("query order status error", err); + } } } @@ -269,18 +255,8 @@ export default { break; } try { - const shellData = { - nftToken: this.nft_Token, - currency: this.value, - tokenId: this.piece - ? this.piece.detail.token_id - : this.data.detail.token_id, - amount: this.piece ? this.cunout : 1, - price: this.shell.price, - marketAddress: CONTRACT_ADDRESS[AppModule.chainId].marketDddress, - }; + this.showLoading(); - console.log(shellData, "shellData", "999999990000000000000000"); const nftres = await this.chainManager.bc.beginNftSell( this.nft_Token, this.value, @@ -306,7 +282,6 @@ export default { }, 1000); }, 1000); } - console.log(nftres, "beginSell"); } catch (err) { this.hideLoading(); this.$emit("handMessage", 0); diff --git a/src/components/market/WeaponBuyDialog.vue b/src/components/market/WeaponBuyDialog.vue index 9adb2f8..0e1fe23 100644 --- a/src/components/market/WeaponBuyDialog.vue +++ b/src/components/market/WeaponBuyDialog.vue @@ -109,12 +109,6 @@ export default { }, methods: { async haldBuy() { - const data = { - currency: this.data.s_currency, - price: this.data.s_price, - marketDddress: CONTRACT_ADDRESS[AppModule.chainId].marketDddress, - }; - console.log(data, "data"); try { this.showLoading(); const nftres = await this.chainManager.bc.beginApproveBuy( @@ -122,7 +116,6 @@ export default { this.data.s_price, CONTRACT_ADDRESS[AppModule.chainId].marketDddress ); - console.log(nftres, "beginSell"); if (nftres.status == true) { this.isApprove = true; this.hideLoading(); @@ -136,22 +129,15 @@ export default { } }, async handBeginBuy() { - const data = { - o_link: this.data.o_link, - marketDddress: CONTRACT_ADDRESS[AppModule.chainId].marketDddress, - }; - console.log(data, "data"); try { this.showLoading(); const nftres = await this.chainManager.bc.beginBuy( this.data.o_link, CONTRACT_ADDRESS[AppModule.chainId].marketDddress ); - console.log(nftres, "beginSell"); if (nftres.status == true) { this.hideLoading(); this.$emit("handMessage", 1); - // this.closeTip() setTimeout(() => { this.$emit("handMessageHide"); this.closeTip(); @@ -182,9 +168,7 @@ export default { this.loadingInstance?.close(); }, closeTip() { - // 分发自定义事件(事件名: closeTip) this.$emit("handBuyHide"); - console.log("closeTip"); }, }, };