修改下链弹窗

This commit is contained in:
yuyongdong 2024-07-22 14:22:53 +08:00
parent c33b30580c
commit 0179f1fa96
4 changed files with 40 additions and 14 deletions

View File

@ -15,7 +15,7 @@ VUE_APP_NET_ID='13371'
VUE_APP_MARKET_CURRENCY='0x52A6c53869Ce09a731CD772f245b97A4401d3348' VUE_APP_MARKET_CURRENCY='0x52A6c53869Ce09a731CD772f245b97A4401d3348'
VUE_APP_MAKEFEE_ADDRESS='0x50A8e60041A206AcaA5F844a1104896224be6F39' VUE_APP_MAKEFEE_ADDRESS='0x50A8e60041A206AcaA5F844a1104896224be6F39'
VUE_APP_LOCKER_ADDRESS='0x2034e51e1a24f8b488610aBBDCc74F3e0cA833df' VUE_APP_LOCKER_ADDRESS='0x2034e51e1a24f8b488610aBBDCc74F3e0cA833df'
VUE_APP_FOUNDER_ADDRESS='0x7f2b4db626d878778e178b4f0c7ba3a2870c6dd0' VUE_APP_FOUNDER_ADDRESS='0x5c16AC8322E5cac8ad235F7e0Dc5d23bffe3ed50'
VUE_APP_EXPLORER_URL='https://explorer.immutable.com' VUE_APP_EXPLORER_URL='https://explorer.immutable.com'
VUE_APP_PRODUCTION=production VUE_APP_PRODUCTION=production

View File

@ -4,8 +4,8 @@ VUE_APP_BASE_API2='https://invitation.counterfire.games'
VUE_APP_GPAL_API='https://game2006api.cebggame.com/' VUE_APP_GPAL_API='https://game2006api.cebggame.com/'
# VUE_APP_PASSPORT_PUBLISHABLE_KEY=pk_imapik-test-8c2FAlWxWAoRITk1v9rH # VUE_APP_PASSPORT_PUBLISHABLE_KEY=pk_imapik-test-8c2FAlWxWAoRITk1v9rH
VUE_APP_PASSPORT_PUBLISHABLE_KEY=pk_imapik-tU10buLqoyLZ0o54rcub VUE_APP_PASSPORT_PUBLISHABLE_KEY=pk_imapik-tU10buLqoyLZ0o54rcub
VUE_APP_PASSPORT_REDIRECT_URI=https://zrguoqth-wwwtest.counterfire.games VUE_APP_PASSPORT_REDIRECT_URI=https://www.counterfire.games
VUE_APP_PASSPORT_LOGOUT_URI=https://zrguoqth-wwwtest.counterfire.games VUE_APP_PASSPORT_LOGOUT_URI=https://www.counterfire.games
VUE_APP_PASSPORT_CLIENT_ID=tTB5eEedqDOHPHMI41sRDGmqAQwus9oE VUE_APP_PASSPORT_CLIENT_ID=tTB5eEedqDOHPHMI41sRDGmqAQwus9oE
# VUE_APP_PASSPORT_CLIENT_ID=0FNfXxQywm7wjdbyLTDzWt4txc53yRrT # VUE_APP_PASSPORT_CLIENT_ID=0FNfXxQywm7wjdbyLTDzWt4txc53yRrT
VUE_APP_PASSPORT_MARKET_ADDRESS=0x7d117aA8BD6D31c4fa91722f246388f38ab1942c VUE_APP_PASSPORT_MARKET_ADDRESS=0x7d117aA8BD6D31c4fa91722f246388f38ab1942c
@ -15,6 +15,10 @@ VUE_APP_NET_ID='13371'
VUE_APP_MARKET_CURRENCY='0x52A6c53869Ce09a731CD772f245b97A4401d3348' VUE_APP_MARKET_CURRENCY='0x52A6c53869Ce09a731CD772f245b97A4401d3348'
VUE_APP_MAKEFEE_ADDRESS='0x50A8e60041A206AcaA5F844a1104896224be6F39' VUE_APP_MAKEFEE_ADDRESS='0x50A8e60041A206AcaA5F844a1104896224be6F39'
VUE_APP_LOCKER_ADDRESS='0x2034e51e1a24f8b488610aBBDCc74F3e0cA833df' VUE_APP_LOCKER_ADDRESS='0x2034e51e1a24f8b488610aBBDCc74F3e0cA833df'
VUE_APP_FOUNDER_ADDRESS='0x7f2b4db626d878778e178b4f0c7ba3a2870c6dd0' VUE_APP_FOUNDER_ADDRESS='0x5c16AC8322E5cac8ad235F7e0Dc5d23bffe3ed50'
VUE_APP_EXPLORER_URL='https://explorer.immutable.com' VUE_APP_EXPLORER_URL='https://explorer.immutable.com'
VUE_APP_PRODUCTION=production VUE_APP_PRODUCTION=production
VUE_APP_NET_ID_MAIN='1'
VUE_APP_LOCKER_ADDRESS_MAIN='0x5c16AC8322E5cac8ad235F7e0Dc5d23bffe3ed50'

View File

@ -242,8 +242,12 @@ const heroLock = async (data) => {
const bc = new BlockChain() const bc = new BlockChain()
let res = await bc.locker.unlockOrMintGameNft(toRaw(data).contract_address,[toRaw(data).token_id]) let res = await bc.locker.unlockOrMintGameNft(toRaw(data).contract_address,[toRaw(data).token_id])
if(res) { if(res) {
let timer = setTimeout(() => { let timer = setTimeout( async () => {
message.success('Unstake success.') // message.success('Unstake success.')
const confirmResult = await createModal(ConfirmDialog, {
title: '',
message: 'Unstake success. It is expected to take 3-4 minutes. Please log in to the original wallet address to check later.'
}).show()
loadingDialogVisible.value = false loadingDialogVisible.value = false
emit('renewMyNft') emit('renewMyNft')
clearTimeout(timer); clearTimeout(timer);
@ -264,10 +268,14 @@ const founderLock = async (data) => {
loadingDialogVisible.value = true loadingDialogVisible.value = true
try { try {
const bc = new BlockChain() const bc = new BlockChain()
let res = await bc.locker.unlockMain(toRaw(data).contract_address,[toRaw(data).token_id]) let res = await bc.locker.unlockMain(data.contract_address,[data.token_id])
if(res) { if(res) {
let timer = setTimeout(() => { let timer = setTimeout( async () => {
message.success('Unstake success.') // message.success('Unstake success.')
const confirmResult = await createModal(ConfirmDialog, {
title: '',
message: 'Unstake success. It is expected to take 3-4 minutes. Please log in to the original wallet address to check later.'
}).show()
loadingDialogVisible.value = false loadingDialogVisible.value = false
emit('renewMyNft') emit('renewMyNft')
clearTimeout(timer); clearTimeout(timer);

View File

@ -383,17 +383,24 @@ const backStaking = async () => {
} }
const heroLock = async () => { const heroLock = async () => {
loadingDialogVisible.value = true
try { try {
const bc = new BlockChain() const bc = new BlockChain()
let res = await bc.locker.unlockOrMintGameNft(detailData.value.nft.contract_address,[detailData.value.nft.token_id]) let res = await bc.locker.unlockOrMintGameNft(detailData.value.nft.contract_address,[detailData.value.nft.token_id])
if(res) { if(res) {
let timer = setTimeout(() => { let timer = setTimeout( async () => {
message.success('Unstake success.') // message.success('Unstake success.')
const confirmResult = await createModal(ConfirmDialog, {
title: '',
message: 'Unstake success. It is expected to take 3-4 minutes. Please log in to the original wallet address to check later.'
}).show()
loadingDialogVisible.value = false
router.go(-1) router.go(-1)
clearTimeout(timer); clearTimeout(timer);
}, 2000); }, 2000);
} }
} catch (e) { } catch (e) {
loadingDialogVisible.value = false
if(e.message.indexOf('rejected') > -1) { if(e.message.indexOf('rejected') > -1) {
message.error('User rejected the request') message.error('User rejected the request')
} else if (e.message.indexOf('select wallet') > -1) { } else if (e.message.indexOf('select wallet') > -1) {
@ -404,17 +411,24 @@ const heroLock = async () => {
} }
} }
const founderLock = async () => { const founderLock = async () => {
loadingDialogVisible.value = true
try { try {
const bc = new BlockChain() const bc = new BlockChain()
let res = await bc.locker.unlockMain(detailData.value.nft.contract_address,[detailData.value.nft.token_id]) let res = await bc.locker.unlockMain(detailData.value.nft.contract_address,[detailData.value.nft.token_id])
if(res) { if(res) {
let timer = setTimeout(() => { let timer = setTimeout( async () => {
message.success('Unstake success.') // message.success('Unstake success.')
const confirmResult = await createModal(ConfirmDialog, {
title: '',
message: 'Unstake success. It is expected to take 3-4 minutes. Please log in to the original wallet address to check later.'
}).show()
loadingDialogVisible.value = false
router.go(-1) router.go(-1)
clearTimeout(timer); clearTimeout(timer);
}, 2000); }, 2000);
} }
} catch (e) { } catch (e) {
loadingDialogVisible.value = false
if(e.message.indexOf('rejected') > -1) { if(e.message.indexOf('rejected') > -1) {
message.error('User rejected the request') message.error('User rejected the request')
} else if (e.message.indexOf('select wallet') > -1) { } else if (e.message.indexOf('select wallet') > -1) {