| | |
| | | <div class="rechargePage box-border font-26"> |
| | | <assets-head :title="$t('快速充币')" /> |
| | | <div class="mt-30 w-full text-center font-36 textColor"> |
| | | {{ coin.toUpperCase() + " " + $t("充值") }} |
| | | {{ symbol.toUpperCase() + " " + $t("充值") }} |
| | | </div> |
| | | <div |
| | | class="pl-30 pr-30 text-center flex flex-col items-center justify-center mt40" |
| | |
| | | </div> |
| | | </div> |
| | | <!-- <div> |
| | | <div class="font-26 textColor">{{ $t('转出地址(选填)') }}</div> |
| | | <div style="position: relative;" class="mt-26 mb-60"> |
| | | <input style="padding-right: 80px;" v-model="enterAddress" |
| | | class="input-view font-26 textColor inputBackground" :placeholder="$t('请输入转出地址')" /> |
| | | <div style="position: absolute;right: 10px;top: 50%;color: #2C78F8;transform: translateY(-50%)" |
| | | @click="enterAddress = address"> |
| | | {{ $t('粘贴') }}</div> |
| | | </div> |
| | | </div> --> |
| | | <div class="mb-60"> |
| | | <div class="font-26 textColor">{{ $t("转出地址(选填)") }}</div> |
| | | <div style="position: relative" class="mt-26 mb-60"> |
| | | <input |
| | | style="padding-right: 80px" |
| | | v-model="enterAddress" |
| | | class="input-view font-26 textColor inputBackground" |
| | | :placeholder="$t('请输入转出地址')" |
| | | /> |
| | | <div |
| | | style=" |
| | | position: absolute; |
| | | right: 10px; |
| | | top: 50%; |
| | | color: #2c78f8; |
| | | transform: translateY(-50%); |
| | | " |
| | | @click="enterAddress = address" |
| | | > |
| | | {{ $t("粘贴") }} |
| | | </div> |
| | | </div> |
| | | </div> --> |
| | | <!-- <div class="mb-60"> |
| | | <div class="font-26 textColor">{{ $t("充币数量") }}</div> |
| | | <div> |
| | | <input |
| | |
| | | :placeholder="$t('请输入充币数量')" |
| | | /> |
| | | </div> |
| | | </div> |
| | | </div> --> |
| | | <!-- <div> |
| | | <div class="font-26 textColor">{{ $t('链名称') }}</div> |
| | | <div class="flex "> |
| | |
| | | item.blockchain_name }}</div> |
| | | </div> |
| | | </div> --> |
| | | <div> |
| | | <!-- <div> |
| | | <div class="font-26 textColor"> |
| | | {{ $t("付款凭证(上传支付详情截图)") }} |
| | | </div> |
| | |
| | | :after-read="afterRead" |
| | | /> |
| | | </div> |
| | | </div> |
| | | </div> --> |
| | | </div> |
| | | <div class="hint-box"> |
| | | <!-- <div class="hint-box"> |
| | | <div class="pl-30 pr-30"> |
| | | <div class="font-26 mb-27 textColor">{{ $t("重要提示") }}</div> |
| | | <div class="font-28 text-grey" v-html="tip"></div> |
| | |
| | | {{ $t("下一步") }} |
| | | </button> |
| | | </div> |
| | | </div> |
| | | </div> --> |
| | | </div> |
| | | </template> |
| | | |
| | |
| | | imgshow: false, |
| | | img: "", |
| | | enterAddress: "", |
| | | symbol: "", |
| | | }; |
| | | }, |
| | | mounted() { |
| | | //获取域名 |
| | | this.nowUrl = "https://" + window.location.hostname; |
| | | this.coin = this.$route.query.symbol; |
| | | this.coin = this.$route.query.coin; |
| | | this.symbol = this.$route.query.symbol; |
| | | this.getData(); |
| | | this.getToken(); |
| | | // https://www.wbfjsfhjdbsh.site/wap/api/cms!get.action?language=en&content_code=002&token=fe3c35583f8a4f12a86b0c13faa75ee6 |
| | |
| | | }, |
| | | methods: { |
| | | getData() { |
| | | Axios.exchange({}).then((res) => { |
| | | if ( |
| | | res.data && |
| | | res.data.filter((item) => { |
| | | return item.userid == this.userInfo.usercode; |
| | | }).length > 0 |
| | | ) { |
| | | Axios.user_wallet({}).then((res) => { |
| | | let trc20 = res.data["wallet_address_USDT(trc20)"].contract_address; |
| | | // let erc20=res.data["wallet_address_USDT(erc20)"].contract_address |
| | | let btc = res.data["wallet_address_BTC"].contract_address; |
| | | let eth = res.data["wallet_address_ETH"].contract_address; |
| | | if (this.coin == "usdt") { |
| | | this.chainList = [ |
| | | { |
| | | address: trc20, |
| | | blockchain_name: "TRC20", |
| | | }, |
| | | // { |
| | | // address:erc20, |
| | | // blockchain_name:'ERC20' |
| | | // }, |
| | | ]; |
| | | } else if (this.coin == "btc") { |
| | | this.chainList = [ |
| | | { |
| | | address: btc, |
| | | blockchain_name: "BTC", |
| | | }, |
| | | ]; |
| | | } else if (this.coin == "eth") { |
| | | this.chainList = [ |
| | | { |
| | | address: eth, |
| | | blockchain_name: "ETH", |
| | | }, |
| | | ]; |
| | | } |
| | | this.address = this.chainList[0].address; |
| | | this.blockchain_name = this.chainList[0].blockchain_name; |
| | | this.getQRCode(); |
| | | }); |
| | | } else { |
| | | Axios.getBlock({ |
| | | coin: this.coin, |
| | | }).then((res) => { |
| | | if (res.code == "0") { |
| | | this.chainList = res.data; |
| | | this.address = res.data[0].address; |
| | | this.blockchain_name = res.data[0].blockchain_name; |
| | | this.getQRCode(); |
| | | } |
| | | }); |
| | | } |
| | | Axios.getBlock({ |
| | | coin: this.coin, |
| | | }).then((res) => { |
| | | console.log(res); |
| | | this.address = res.address; |
| | | // this.blockchain_name = res.data[0].blockchain_name; |
| | | this.getQRCode(); |
| | | }); |
| | | }, |
| | | changeBlockchain(index) { |
| | |
| | | this.$toast(this.$t("请输入数字")); |
| | | return; |
| | | } |
| | | |
| | | if (this.amount) { |
| | | Axios.rechargeApply({ |
| | | session_token: this.session_token, |
| | | amount: this.amount, |
| | | from: this.enterAddress, |
| | | blockchain_name: "TRC20", |
| | | blockchain_name: this.coin.toUpperCase(), |
| | | img: this.submitImg, |
| | | coin: this.coin, |
| | | coin: this.symbol.toUpperCase(), |
| | | channel_address: this.address, |
| | | tx: "", |
| | | }) |