| | |
| | | <div class="css-fqmucm" v-if="walletList.length > 0"> |
| | | {{ $t("message.user.dui5") }} |
| | | <div class="balance css-vurnku"> |
| | | {{ itemChoose?.value }} |
| | | {{ itemChoose?.volume }} |
| | | </div> |
| | | {{ itemChoose?.name }} |
| | | {{ itemChoose?.name?.split("/")[0] }} |
| | | </div> |
| | | </div> |
| | | <!-- 卖出 --> |
| | |
| | | v-if="walletList.length > 0" |
| | | > |
| | | <img |
| | | :src="handleSymbolImg(itemChoose?.name)" |
| | | :src="handleSymbolImg(itemChoose?.symbol)" |
| | | class="css-1bmz5aq" |
| | | /> |
| | | {{ itemChoose?.name }} |
| | | {{ itemChoose?.name?.split("/")[0] }} |
| | | </div> |
| | | <el-icon><CaretBottom /></el-icon> |
| | | </div> |
| | |
| | | <div class="css-1pysja1"> |
| | | <div class="css-176wmh3"> |
| | | <img |
| | | :src="handleSymbolImg(item.name)" |
| | | :src="handleSymbolImg(item.symbol)" |
| | | class="css-1m0agl6" |
| | | /> |
| | | {{ item.name }} |
| | | {{ item.name?.split("/")[0] }} |
| | | </div> |
| | | </div> |
| | | </div> |
| | |
| | | > |
| | | <div class="css-9wgib6 pl-16" v-if="walletList.length > 0"> |
| | | <img |
| | | :src="handleSymbolImg(itemChoose1?.name)" |
| | | :src="handleSymbolImg(itemChoose1?.symbol)" |
| | | class="css-1bmz5aq" |
| | | /> |
| | | {{ itemChoose1?.name }} |
| | | {{ itemChoose1?.name?.split("/")[0] }} |
| | | </div> |
| | | <el-icon><CaretBottom /></el-icon> |
| | | <!-- </div> --> |
| | |
| | | <div class="css-1pysja1"> |
| | | <div class="css-176wmh3"> |
| | | <img |
| | | :src="handleSymbolImg(item.name)" |
| | | :src="handleSymbolImg(item.symbol)" |
| | | class="css-1m0agl6" |
| | | /> |
| | | {{ item.name }} |
| | | {{ item.name?.split("/")[0] }} |
| | | </div> |
| | | </div> |
| | | </div> |
| | |
| | | </template> |
| | | <script> |
| | | import Axios2 from "@/api/wallet.js"; |
| | | import Axios from "@/utils/http"; |
| | | import { handleSymbolImg } from "@/utils"; |
| | | import { Search, ArrowLeftBold, CaretBottom } from "@element-plus/icons-vue"; |
| | | export default { |
| | |
| | | this.InputMoney = ""; |
| | | }, |
| | | OnClickMax() { |
| | | this.InputMoney = this.itemChoose?.value; |
| | | this.InputMoney = this.itemChoose?.volume; |
| | | }, |
| | | //获取所有币种及其价值 |
| | | getWalletList() { |
| | | Axios2.getWalletList().then((res) => { |
| | | var jsonArray = res; |
| | | this.walletList = [{ name: "USDT", value: 0 }]; |
| | | for (var i in jsonArray.data) { |
| | | if (i == "USDT") { |
| | | this.walletList[0].value = jsonArray.data[i].money; |
| | | } else { |
| | | this.walletList.push({ |
| | | name: i, |
| | | value: jsonArray.data[i].amount, |
| | | }); |
| | | } |
| | | } |
| | | // Axios2.getWalletList() |
| | | Axios.fetch("wap/api/wallet!getAll.action").then((res) => { |
| | | this.walletList = res.data.extends; |
| | | // this.walletList = [{ name: "USDT", value: 0 }]; |
| | | // for (var i in jsonArray.data) { |
| | | // if (i == "USDT") { |
| | | // this.walletList[0].value = jsonArray.data[i].volume; |
| | | // } else { |
| | | // this.walletList.push({ |
| | | // name: i, |
| | | // value: jsonArray.data[i].amount, |
| | | // }); |
| | | // } |
| | | // } |
| | | |
| | | this.showWallet1 = this.walletList; |
| | | this.showWallet2 = this.walletList; |
| | |
| | | }, |
| | | getFee() { |
| | | const params = { |
| | | symbol: this.itemChoose.name, |
| | | symbol_to: this.itemChoose1.name, |
| | | symbol: this.itemChoose.symbol, |
| | | symbol_to: this.itemChoose1.symbol, |
| | | volume: this.InputMoney, |
| | | }; |
| | | |
| | |
| | | }, |
| | | getTrans() { |
| | | var params = { |
| | | symbol: this.itemChoose?.name, |
| | | symbol_to: this.itemChoose1?.name, |
| | | symbol: this.itemChoose?.symbol, |
| | | symbol_to: this.itemChoose1?.symbol, |
| | | volume: this.InputMoney, |
| | | session_token: this.session_token, |
| | | }; |