|
|
|
@ -116,6 +116,19 @@ |
|
|
|
|
|
|
|
</v-input> |
|
|
|
</view> |
|
|
|
<view class="d-flex align-center p-y-xs m-t-ms justify-between color-light fn-15"> |
|
|
|
<span>{{ $t("safe.a5") }}:</span> |
|
|
|
</view> |
|
|
|
<view class="d-flex align-end p-y-xs justify-between bg-form-panel-3 rounded-xs p-sm p-x-ms"> |
|
|
|
<v-input type="text" v-model="form.emailcode" class=" w-8/12 color-light fn-13" |
|
|
|
:placeholder="$t('safe.a6')"></v-input> |
|
|
|
<view class="d-flex align-end"> |
|
|
|
<view class="all color-theme-1 m-l-md flex-shrink" @click="getEmailCode"> |
|
|
|
<text v-if="!getEmailCodeLock">{{ $t("common.getCode") }}</text> |
|
|
|
<text v-else>{{ daojishi }}</text> |
|
|
|
</view> |
|
|
|
</view> |
|
|
|
</view> |
|
|
|
</view> |
|
|
|
<view class="form bg-panel-3 p-x-lg p-y-md"> |
|
|
|
<ul class="fn-md rounded-md m-y-xs line-height-2"> |
|
|
|
@ -211,6 +224,7 @@ |
|
|
|
<script> |
|
|
|
import coinList from "./coin-list"; |
|
|
|
import Wallet from "@/api/wallet"; |
|
|
|
import Member from "@/api/member"; |
|
|
|
import formData from "@/utils/class/date"; |
|
|
|
|
|
|
|
export default { |
|
|
|
@ -229,14 +243,18 @@ export default { |
|
|
|
address: "", |
|
|
|
addressType: "", |
|
|
|
code_type: 1, |
|
|
|
code: '' |
|
|
|
code: '', |
|
|
|
emailcode: '', |
|
|
|
}, |
|
|
|
withdrawFee: {}, |
|
|
|
list: [], |
|
|
|
page: 1, |
|
|
|
loadMore: true, |
|
|
|
secondaryShow: false, |
|
|
|
type: 'draw' |
|
|
|
type: 'draw', |
|
|
|
getEmailCodeLock: false, |
|
|
|
JStime: 0, |
|
|
|
tiemr: null, |
|
|
|
}; |
|
|
|
}, |
|
|
|
computed: { |
|
|
|
@ -246,6 +264,10 @@ export default { |
|
|
|
(item) => item.coin_name == this.coin |
|
|
|
); |
|
|
|
}, |
|
|
|
daojishi(){ |
|
|
|
|
|
|
|
return '('+this.JStime + 's' + ')'; |
|
|
|
} |
|
|
|
}, |
|
|
|
watch: { |
|
|
|
coin(n) { |
|
|
|
@ -295,6 +317,28 @@ export default { |
|
|
|
this.withdrawFee = res.data; |
|
|
|
}); |
|
|
|
}, |
|
|
|
// 獲取邮箱验证码 |
|
|
|
getEmailCode(){ |
|
|
|
if(this.getEmailCodeLock){return}; |
|
|
|
this.JStime = 300; |
|
|
|
this.tiemr = setInterval(()=>{ |
|
|
|
if(this.JStime===0){ |
|
|
|
this.getEmailCodeLock = false; |
|
|
|
clearInterval(this.tiemr); |
|
|
|
return; |
|
|
|
} |
|
|
|
this.JStime--; |
|
|
|
}, 1000) |
|
|
|
this.getEmailCodeLock = true; |
|
|
|
Member.getWdcode().then(res=>{ |
|
|
|
// console.log(res); |
|
|
|
if(res.code=='4001'){ |
|
|
|
this.$toast(res.message); |
|
|
|
}else{ |
|
|
|
this.$toast(this.$t('common.sendSuccess')); |
|
|
|
} |
|
|
|
}) |
|
|
|
}, |
|
|
|
// 发起提币 |
|
|
|
toDraw() { |
|
|
|
if (!this.form.address) { |
|
|
|
@ -305,6 +349,10 @@ export default { |
|
|
|
this.$toast(this.$t('assets.c2')) |
|
|
|
return |
|
|
|
} |
|
|
|
if (!this.form.emailcode) { |
|
|
|
this.$toast(this.$t('safe.a6')) |
|
|
|
return |
|
|
|
} |
|
|
|
let data = this.withdrawFee |
|
|
|
if (data.withdraw_switch == 1) { |
|
|
|
this.secondaryShow = true |
|
|
|
|