disable clam of game coin

This commit is contained in:
cebgcontract 2022-05-29 13:54:52 +08:00
parent 9180f5e18b
commit f7b9d9092f

View File

@ -289,40 +289,41 @@ export default class WalletPanel extends Vue {
} }
async onGameCardClicked(data: ICoinData) { async onGameCardClicked(data: ICoinData) {
console.log('on game card clicked: ', data) this.comingSoon?.()
let value = 0 // console.log('on game card clicked: ', data)
try { // let value = 0
value = await this.pickAmount({ // try {
min: 1, // value = await this.pickAmount({
max: data.amount, // min: 1,
title: 'Please input amount to claim' // max: data.amount,
}) // title: 'Please input amount to claim'
} catch (err) { // })
this.$message({ // } catch (err) {
type: 'info', // this.$message({
message: 'User cancel' // type: 'info',
}) // message: 'User cancel'
} // })
if (!value) { // }
return // if (!value) {
} // return
const postData = { // }
account: AppModule.accountId, // const postData = {
type: data.id === 'gold' ? 1 : 2, // account: AppModule.accountId,
amount: value + '000000000000000000' // type: data.id === 'gold' ? 1 : 2,
} // amount: value + '000000000000000000'
this.loadingInstance = this.$loading({ background: 'rgba(0, 0, 0, 0.8)' }) // }
try { // this.loadingInstance = this.$loading({ background: 'rgba(0, 0, 0, 0.8)' })
const res: any = await withdrawal(postData) // try {
console.log('withdrawal result: ', res) // const res: any = await withdrawal(postData)
const seqId = res.seq_id // console.log('withdrawal result: ', res)
this.saveTmpOrderInfo(seqId, 1) // const seqId = res.seq_id
this.beginTraceOrderStatus(seqId, 1) // this.saveTmpOrderInfo(seqId, 1)
this.loadingInstance?.close() // this.beginTraceOrderStatus(seqId, 1)
} catch (err) { // this.loadingInstance?.close()
this.loadingInstance?.close() // } catch (err) {
} // this.loadingInstance?.close()
console.log('begin claim') // }
// console.log('begin claim')
} }
async updateGameCoins() { async updateGameCoins() {