| | |
| | | import AxiosWithdraw from "@/API/withdraw.js" |
| | | import assetsHead from "@/components/assets-head"; |
| | | import BarScan from '@/components/scan/scan.vue'; |
| | | import { _getAllWallet } from "@/API/fund.api"; |
| | | import { _getAllWallet,walletGrther } from "@/API/fund.api"; |
| | | import AxiosUser from "@/API/userCenter"; |
| | | import { mapGetters } from "vuex"; |
| | | export default { |
| | |
| | | }, |
| | | //获取钱包余额 |
| | | getAvailable(symbol) { |
| | | _getAllWallet().then((res) => { |
| | | let walletList = res.extends; |
| | | let initObj = walletList.find(item => { |
| | | return item.symbol.toLowerCase() == symbol.toLowerCase() |
| | | }) |
| | | this.usdtBalance = initObj.usable |
| | | walletGrther().then((res) => { |
| | | console.log('symbol.toLowerCase()',symbol.toLowerCase()); |
| | | if(symbol.toLowerCase()=='usdt'){ |
| | | this.usdtBalance = res.usdtMoney |
| | | }else if(symbol.toLowerCase()=='eth'){ |
| | | this.usdtBalance = res.ethMoney |
| | | }else{ |
| | | this.usdtBalance = res.btcMoney |
| | | } |
| | | // let walletList = res.extends; |
| | | // let initObj = walletList.find(item => { |
| | | // return item.symbol.toLowerCase() == symbol.toLowerCase() |
| | | // }) |
| | | // this.usdtBalance = initObj.usable |
| | | }); |
| | | }, |
| | | //点全部 |