10.10综合交易所原始源码_移动端
1
admin
2026-01-06 03043192ddf00f9a36b7454799a9152cd1b50a0b
src/views/cryptos/Withdraw/withdrawPage.vue
@@ -124,6 +124,7 @@
import assetsHead from "@/components/Transform/assets-head/index.vue";
import BarScan from '@/components/Transform/scan/scan.vue';
import { _getAllWallet } from "@/service/fund.api";
import { _getSyspara } from '@/service/trade.api.js'
export default {
  name: "withdrawPage",
  components: {
@@ -135,10 +136,10 @@
  data() {
    return {
      tip: '',
      value: 'USDT', //选中的币种
      value: 'USDC', //选中的币种
      show: false,
      showSymbol: false,
      actions: [{ name: 'USDT' }, { name: 'BTC' }, { name: 'ETH' }],
      actions: [{ name: 'USDC' }],
      blockList: [],
      blockchainIndex: "",
      usdtBalance: "", //余额
@@ -152,12 +153,20 @@
      percent: 0,
      numLenth: 3,
      routerType: '',
      // 获取最低限额接口时需要的参数
      xeList: {
        "USDT": 'withdraw_limit',
        "BTC": 'withdraw_limit_btc',
        "ETH": 'withdraw_limit_eth',
        "USDC": 'withdraw_limit_usdc',
      },
      minXE: 0, // 最小提现限额
    }
  },
  created() {
    this.getBlock(this.value);
    this.getAvailable(this.actions[0].name);
    this.getXE();
    Axios.getRechargeTips({
      language: this.$i18n.locale,
@@ -171,7 +180,8 @@
    })
    _withdrawFee({
      amount: 1,
      channel: this.value + '_' + this.blockName
      channel: this.value + '_' + this.blockName,
      type: 'cryptos' // 加密货币提取时传cryptos
    }).then((res) => {
      this.withdraw_fee_type = res.withdraw_fee_type
      if (this.withdraw_fee_type == 'rate') {
@@ -190,7 +200,6 @@
      console.log(this.$route.query.type);
      this.routerType === 'exchange' ? this.$router.push('/Record/DepositAndWithdrawal') : this.goRouter('/cryptos/assetsCenter/rechargeWithdrawRecord');
    },
    getwei(value, numLenth) {
      console.log(numLenth)
      let str = value.toString();
@@ -224,6 +233,10 @@
        showToast(this.$t('金额不足'))
        return
      }
      if (this.amount < this.minXE) {
        showToast(this.$t('提现不得小于限额') + ' ' + this.minXE)
        return
      }
      this.show = true;
    },
    goRouter(params) {
@@ -248,11 +261,13 @@
      this.withdraw_fee_type = ''
      this.getBlock(item.name);
      this.getAvailable(item.name)
      this.getXE(item.name)
      if (item.name == 'BTC' || item.name == 'ETH') {
        this.numLenth = 7
        _withdrawFee({
          amount: 1,
          channel: this.value + '_' + this.blockName
          channel: this.value + '_' + this.blockName,
          type: 'cryptos' // 加密货币提取时传cryptos
        }).then((res) => {
          this.withdraw_fee_type = res.withdraw_fee_type
          if (this.withdraw_fee_type == 'fixed') {
@@ -264,6 +279,12 @@
      } else {
        this.numLenth = 3
      }
    },
    // 根据币种获取最低提现限额
    async getXE(name = "USDC") {
      let code = this.xeList[name]
      let res = await _getSyspara({ code })
      this.minXE = res[code]
    },
    //根据币种获取链地址
    getBlock(symbol) {
@@ -307,7 +328,8 @@
      if (this.withdraw_fee_type == 'part') {
        _withdrawFee({
          amount: this.amount,
          channel: this.value + '_' + this.blockName
          channel: this.value + '_' + this.blockName,
          type: 'cryptos' // 加密货币提取时传cryptos
        }).then((res) => {
          console.log(res)
          this.fee = res.fee;