bug fix: assets card price show error
This commit is contained in:
parent
1e88d573d3
commit
4b9a0e8acb
@ -18,7 +18,7 @@
|
|||||||
{{ nftPrice }}
|
{{ nftPrice }}
|
||||||
<!-- {{cardPrice(nftData)}} -->
|
<!-- {{cardPrice(nftData)}} -->
|
||||||
</span>
|
</span>
|
||||||
<img src="@/assets/img/marketplace/ETHicon.png" alt="图片">
|
<img :src="icon" alt="">
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div v-if="nftData.type == 0 && nftData.on_sale == 0" class="enabled" @click="lockToGame('redeem')">
|
<div v-if="nftData.type == 0 && nftData.on_sale == 0" class="enabled" @click="lockToGame('redeem')">
|
||||||
@ -159,14 +159,16 @@ const lockToGameConfirm = async () => {
|
|||||||
|
|
||||||
|
|
||||||
// 获取出售中价格价格
|
// 获取出售中价格价格
|
||||||
const nftPrice = ref()
|
const nftPrice = ref('-')
|
||||||
|
const icon = ref('')
|
||||||
const cardPrice = async (val) => {
|
const cardPrice = async (val) => {
|
||||||
let nftData = await getNftData(toRaw(val))
|
let nftData = await getNftData(toRaw(val))
|
||||||
if(nftData.event) {
|
if (nftData?.event?.data) {
|
||||||
nftPrice.value = priceCalculated(nftData.event.data.buy[0].amount)
|
const data = formatPrice(nftData?.event?.data)
|
||||||
} else {
|
icon.value = data.icon
|
||||||
return false
|
nftPrice.value = data.tokenAmount
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user