Browse Source

提现充值划转等完成

master
j1ack 3 years ago
parent
commit
25ea09dd83
  1. 174
      pages/me/transfer.vue
  2. 1115
      pages/recharge/recharge.vue
  3. 371
      pages/recharge/rechargeRecord.vue
  4. 94
      pages/withdrawal/addAddress.vue
  5. 612
      pages/withdrawal/chooseAddress.vue
  6. 1470
      pages/withdrawal/withdrawal.vue
  7. 401
      pages/withdrawal/withdrawalRecord.vue
  8. 7
      utils/language/en_US.js
  9. 1624
      utils/qrCode/wxqrcode.js

174
pages/me/transfer.vue

@ -7,7 +7,7 @@
<!-- coin选择框 --> <!-- coin选择框 -->
<view class="text">{{ i18n.SelectCurrency }}</view> <view class="text">{{ i18n.SelectCurrency }}</view>
<view class="input-item"> <view class="input-item">
<u-input class="input" v-model="coin" color="#fff" fontSize="32rpx" border="none" <u-input class="input" v-model="coinInfo.coinCode" color="#fff" fontSize="32rpx" border="none"
:placeholder="i18n.PleaseChooseCoin"> :placeholder="i18n.PleaseChooseCoin">
</u-input> </u-input>
<view class="downSelect" @click="USDTPopupShow = true"></view> <view class="downSelect" @click="USDTPopupShow = true"></view>
@ -15,7 +15,7 @@
<!-- form地址选择框 --> <!-- form地址选择框 -->
<view class="text">{{ i18n.From }}</view> <view class="text">{{ i18n.From }}</view>
<view class="input-item"> <view class="input-item">
<u-input class="input" v-model="coin" color="#fff" fontSize="32rpx" border="none" <u-input class="input" v-model="coinInfo.fromWays" color="#fff" fontSize="32rpx" border="none"
:placeholder="i18n.OptionAccount"> :placeholder="i18n.OptionAccount">
</u-input> </u-input>
<view class="downSelect" @click="accountPopupShow = true"></view> <view class="downSelect" @click="accountPopupShow = true"></view>
@ -23,27 +23,30 @@
<!-- to地址选择框 --> <!-- to地址选择框 -->
<view class="text">{{ i18n.To }}</view> <view class="text">{{ i18n.To }}</view>
<view class="input-item"> <view class="input-item">
<u-input class="input" v-model="coin" color="#fff" fontSize="32rpx" border="none" <u-input class="input" v-model="coinInfo.toWays" color="#fff" fontSize="32rpx" border="none"
:placeholder="i18n.TradingAccount"> :placeholder="i18n.TradingAccount">
</u-input> </u-input>
<view class="downSelect" @click="accountPopupShow = true"></view> <view class="downSelect" @click="accountPopupShowTo = true"></view>
</view> </view>
<!-- 数量 --> <!-- 数量 -->
<view class="text">{{ i18n.TransferNumber }}</view> <view class="text">{{ i18n.TransferNumber }}</view>
<view class="input-item"> <view class="input-item">
<u-input class="input" v-model="coin" color="#fff" fontSize="32rpx" border="none" <u-input class="input" v-model="coinInfo.tranAmt" color="#fff" fontSize="32rpx" border="none"
:placeholder="i18n.PleaseEnterNumber"> :placeholder="i18n.PleaseEnterNumber">
</u-input> </u-input>
<view class="numberDownSelect">USDT <view class="all">{{i18n.ALL}}</view> <view class="numberDownSelect">{{coinInfo.coinCode||''}}
<view class="all" @click="coinInfo.tranAmt=coinWayInfo.userCapital">{{i18n.ALL}}</view>
</view> </view>
</view> </view>
<view class="Usable">{{ i18n.Usable }} <view class="Usable">{{ i18n.Usable }}
<view class="number">{{info.userCapital}}{{info.coinCode}}</view>
<view class="number">{{coinWayInfo.userCapital>=0?coinWayInfo.userCapital:info.userCapital}}{{coinWayInfo.coinCode?coinWayInfo.coinCode:info.coinCode}}</view>
</view> </view>
</view> </view>
<!-- 按钮 --> <!-- 按钮 -->
<u-button class="transferButton" color="#00E8A2" throttleTime="500">{{ <u-button class="transferButton" color="#00E8A2" throttleTime="500" :disabled="!transferDis"
@click="transfer">{{
i18n.Transfer i18n.Transfer
}}</u-button> }}</u-button>
@ -55,47 +58,79 @@
<scroll-view scroll-y="true" style="height: 432rpx;" scroll-with-animation="true" <scroll-view scroll-y="true" style="height: 432rpx;" scroll-with-animation="true"
@touchmove.stop.prevent=""> @touchmove.stop.prevent="">
<radio-group class="radioGroup" @change="USDTRadioChange" v-model="USDTRadioValue"> <radio-group class="radioGroup" @change="USDTRadioChange" v-model="USDTRadioValue">
<label class="checkBox" v-for="(item, index) in 10" :key="index"> <label class="checkBox" v-for="(item, index) in info.coinList" :key="index"
@click="radioChange(item)">
<view class="icon"> <view class="icon">
<u-icon name="../../static/maskets/bye.png" size="52rpx" width="52rpx"></u-icon> <u-icon :name="baseURL+'/coins/'+item.enname+'.png'" size="52rpx" width="52rpx">
</u-icon>
</view> </view>
<view class="iconName"> <view class="iconName">
<view class="top">USDT</view> <view class="top">{{item.enname}}</view>
<view class="bottom">BTC</view> <view class="bottom">{{item.useCapital}}{{" "}}{{item.code}}</view>
</view> </view>
<radio color="#00E8A2" shape="square" :checked="coinInfo.coinCode==item.enname"></radio>
<radio color="#00E8A2" shape="square"></radio>
</label> </label>
</radio-group> </radio-group>
</scroll-view> </scroll-view>
<u-button class="button" color="#00E8A2" throttleTime="500" @click="USDTPopupShow = false">OK <u-button class="button" color="#00E8A2" throttleTime="500" @click="getCoin">OK
</u-button> </u-button>
</view> </view>
</u-popup> </u-popup>
<!-- account账户按钮通知弹出层 --> <!-- account账户按钮form通知弹出层 -->
<u-popup class="accountPopup" :show="accountPopupShow" round="40rpx" mode="bottom" <u-popup class="accountPopup" :show="accountPopupShow" round="40rpx" mode="bottom"
@close="accountPopupShow = false" @open="accountPopupShow = true" bgColor="#211F32"> @close="accountPopupShow = false" @open="accountPopupShow = true" bgColor="#211F32">
<view class="content"> <view class="content">
<view class="close" @click="accountPopupShow = false"></view> <view class="close" @click="accountPopupShow = false"></view>
<scroll-view scroll-y="true" style="height: 200rpx;" scroll-with-animation="true" <scroll-view scroll-y="true" style="height: 200rpx;" scroll-with-animation="true"
@touchmove.stop.prevent=""> @touchmove.stop.prevent="">
<radio-group class="radioGroup" @change="accountRadioChange" v-model="accountRadioValue"> <radio-group class="radioGroup" >
<label class="checkBox" v-for="(item, index) in 3" :key="index"> <!-- v-for="(item, index) in 3" :key="index" -->
<view class="name">Option account</view> <label class="checkBox" @click="getAccount('exchange','form')">
<radio color="#00E8A2" shape="square"></radio> <view class="name">Balance account</view>
<radio color="#00E8A2" shape="square" :checked="transCoinInfo.fromWays=='exchange'"></radio>
</label>
<label class="checkBox" @click="getAccount('contract','form')">
<view class="name">Contract account</view>
<radio color="#00E8A2" shape="square" :checked="transCoinInfo.fromWays=='contract'"></radio>
</label> </label>
</radio-group> </radio-group>
</scroll-view> </scroll-view>
<u-button class="button" color="#00E8A2" throttleTime="500" @click="accountPopupShow = false">OK <u-button class="button" color="#00E8A2" throttleTime="500" @click="getCoinOrAccount">OK
</u-button> </u-button>
</view> </view>
</u-popup> </u-popup>
<!-- account账户按钮to通知弹出层 -->
<u-popup class="accountPopup" :show="accountPopupShowTo" round="40rpx" mode="bottom"
@close="accountPopupShowTo = false" @open="accountPopupShowTo = true" bgColor="#211F32">
<view class="content">
<view class="close" @click="accountPopupShowTo = false"></view>
<scroll-view scroll-y="true" style="height: 200rpx;" scroll-with-animation="true"
@touchmove.stop.prevent="">
<radio-group class="radioGroup" >
<!-- v-for="(item, index) in 3" :key="index" -->
<label class="checkBox" @click="getAccount('contract','to')">
<view class="name">Contract account</view>
<radio color="#00E8A2" shape="square" :checked="transCoinInfo.toWays=='contract'"></radio>
</label>
<label class="checkBox" @click="getAccount('exchange','to')">
<view class="name">Balance account</view>
<radio color="#00E8A2" shape="square" :checked="transCoinInfo.toWays=='exchange'"></radio>
</label>
</radio-group>
</scroll-view>
<u-button class="button" color="#00E8A2" throttleTime="500" @click="getCoinOrAccount">OK
</u-button>
</view>
</u-popup>
</view> </view>
</view> </view>
@ -103,14 +138,31 @@
<script> <script>
import api from '@/utils/api' import api from '@/utils/api'
import constant from '@/utils/constant.js';
export default { export default {
name: "transfer", name: "transfer",
data() { data() {
return { return {
info:{}, type:'',
coinWayInfo:{},
transCoinInfo:{
coinCode:null,
fromWays:null,
},
coinCode: null,
coinCode2: null,
coinInfo: {
coinCode: null,
fromWays: null,
toWays: null,
tranAmt: null,
},
baseURL: '',
info: {},
coin: '', coin: '',
USDTPopupShow: false, USDTPopupShow: false,
accountPopupShow: false, accountPopupShow: false,
accountPopupShowTo: false,
USDTRadioValue: '', USDTRadioValue: '',
accountRadioValue: '', accountRadioValue: '',
}; };
@ -119,24 +171,86 @@
i18n() { i18n() {
return this.$t("me"); return this.$t("me");
}, },
transferDis() {
return this.coinInfo.coinCode && this.coinInfo.fromWays && this.coinInfo.toWays && this.coinInfo.tranAmt
},
}, },
onLoad() { onLoad() {
this.baseURL = constant.BASE_URL
this.getInfo() this.getInfo()
}, },
onShow() {}, onShow() {},
methods: { methods: {
//
reset(){
this.type=''
this.coinWayInfo={}
this.transCoinInfo={
coinCode:null,
fromWays:null,
}
this.coinCode=null,
this.coinCode2=null,
this.coinInfo={
coinCode: null,
fromWays: null,
toWays: null,
tranAmt: null,
}
},
getAccount(e,type){
this.type=type
if(type=='form'){
this.transCoinInfo.fromWays=e
}else{
this.transCoinInfo.toWays=e
}
this.$forceUpdate()
},
//
transfer() {
api.transfer(this.coinInfo).then(res => {
uni.$u.toast(this.$t("login").Transfersucceeded)
this.reset()
setTimeout(() => {
this.getInfo()
}, 1200)
})
},
//
radioChange(e) {
this.coinCode = e.enname
this.coinCode2 = e.code
},
//
getCoin() {
this.coinInfo.coinCode = this.coinCode
this.coinInfo.coinCode2 = this.coinCode2
this.USDTPopupShow = false
},
//
getCoinOrAccount() {
this.transCoinInfo.coinCode=this.coinInfo.coinCode2
this.coinInfo.fromWays=this.transCoinInfo.fromWays
this.coinInfo.toWays=this.transCoinInfo.toWays
if(this.type=='to'){
this.accountPopupShowTo = false
return;
}
api.changeCoinWays(this.transCoinInfo).then(res => {
this.coinWayInfo=res
this.accountPopupShow = false
})
},
//
getInfo() { getInfo() {
api.getTransferConfig({}).then(res => { api.getTransferConfig({}).then(res => {
console.log(res) console.log(res)
this.info=res this.info = res
}) })
}, },
USDTRadioChange(e) { USDTRadioChange(e) {},
console.log(e);
},
accountRadioChange(e) {
console.log(e);
}
}, },
} }

1115
pages/recharge/recharge.vue

File diff suppressed because it is too large

371
pages/recharge/rechargeRecord.vue

@ -1,159 +1,228 @@
<template> <template>
<view class="main"> <view class="main">
<!-- nav --> <!-- nav -->
<navigation>{{ i18n.RechargeRecord }}</navigation> <navigation>{{ i18n.RechargeRecord }}</navigation>
<!-- headBtn --> <!-- headBtn -->
<view class="head"> <view class="head">
<view class="headItem" @click="pageState = 'coinRecharge'" <view class="headItem" @click="form.type = 'crypto',getList()"
:class="{ select: pageState === 'coinRecharge' }"> :class="{ select: form.type === 'crypto' }">
{{ i18n.CoinRecharge }} {{ i18n.CoinRecharge }}
</view> </view>
<view class="headItem" @click="pageState = 'cashRecharge'" <view class="headItem" @click="form.type = 'online',getList()"
:class="{ select: pageState === 'cashRecharge' }"> :class="{ select:form.type === 'online' }">
{{ i18n.CashRecharge }} {{ i18n.CashRecharge }}
</view> </view>
</view> </view>
<view class="cardList"> <view class="cardList">
<view class="card" v-for="(item, index) in 4" :key="index"> <view class="card" v-for="(item, index) in userInfoObj" :key="index">
<!-- 卡片条件渲染 --> <!-- 卡片条件渲染 -->
<!-- balance --> <!-- balance -->
<card-header v-if="pageState === 'coinRecharge'" iconName="../../static/recharge/money-recive.png" <!-- <card-header v-if="form.type === 'crypto'" iconName="../../static/recharge/money-recive.png"
:title="'904.29483230ACTA'" rightName="Succeed" fontColor="#00E8A2"> :title="'904.29483230ACTA'" rightName="Succeed" fontColor="#00E8A2">
</card-header> </card-header> -->
<view class="dataBody" v-if="pageState === 'coinRecharge'"> <card-header v-if="form.type === 'crypto'" :iconName="baseURL+'/coins/'+item.coinCode+'.png'"
<view style="padding:20rpx 32rpx;"> :title="item.tranAmt+item.coinCode"
<key-value-row :keyName="i18n.OrderID" :value="'293829773920223873676'"></key-value-row> :rightName="item.orderStatus=='pay_unpaid'?'Unpaid':item.orderStatus=='pay_success'?'Success':
<key-value-row :keyName="i18n.Fees" :value="'10.0922'"></key-value-row> item.orderStatus=='pay_failure'?'Failed':item.orderStatus=='pay_processing'?'Paying':'Closed'"
<key-value-row :keyName="i18n.Time" :value="'2022/08/06 14:50:34'"></key-value-row> :fontColor="item.orderStatus=='pay_unpaid'?'#F2FE8D':item.orderStatus=='pay_success'?'#00E8A2':
</view> item.orderStatus=='pay_failure'?'#F4506A':item.orderStatus=='pay_processing'?'#00D1FF':'#A1A0A8'">
<view style="border-top: 2rpx solid #323045;padding:0rpx 32rpx; margin-bottom: 20rpx;"> </card-header>
<show-more> <view class="dataBody" v-if="form.type === 'crypto'">
<key-value-row :keyName="i18n.Address" :value="'dhiukyfdhi8797979870800'"></key-value-row> <view style="padding:20rpx 32rpx;">
<key-value-row :keyName="i18n.Hash" :value="'dhiukyfdhi8797979870800'"></key-value-row> <key-value-row :keyName="i18n.OrderID" :value="item.orderNo"></key-value-row>
<view class="text">Postscript : ontact customer service on the top-left corner for identity <key-value-row :keyName="i18n.Fees" :value="(item.tranAmt-(parseInt(item.realAmount,16)))+item.coinCode"></key-value-row>
verific <key-value-row :keyName="i18n.Time" :value="item.timestr"></key-value-row>
</view> </view>
</show-more> <view style="border-top: 2rpx solid #323045;padding:0rpx 32rpx; margin-bottom: 20rpx;">
</view> <show-more>
</view> <key-value-row :keyName="i18n.Address" :value="item.toAddress"></key-value-row>
<key-value-row :keyName="i18n.Hash" :value="item.txid"></key-value-row>
</show-more>
<!-- contarct --> </view>
<card-header v-if="pageState === 'cashRecharge'" iconName="../../static/recharge/money-recive.png" </view>
:title="'904.29483230ACTA'" rightName="Succeed" fontColor="#00E8A2">
</card-header>
<view class="dataBody" v-if="pageState === 'cashRecharge'"> <!-- contarct -->
<view style="padding:20rpx 32rpx;"> <card-header v-if="form.type === 'online'" iconName="../../static/recharge/money-recive.png"
<key-value-row :keyName="i18n.OrderID" :value="'293829773920223873676'"></key-value-row> :title="item.tranAmt+item.coinCode"
<key-value-row :keyName="i18n.Fees" :value="'10.0922'"></key-value-row> :rightName="item.orderStatus=='pay_unpaid'?'Unpaid':item.orderStatus=='pay_success'?'Success':
<key-value-row :keyName="i18n.Time" :value="'2022/08/06 14:50:34'"></key-value-row> item.orderStatus=='pay_failure'?'Failed':item.orderStatus=='pay_processing'?'Paying':'Closed'"
</view> :fontColor="item.orderStatus=='pay_unpaid'?'#F2FE8D':item.orderStatus=='pay_success'?'#00E8A2':
<view style="border-top: 2rpx solid #323045;padding:0rpx 32rpx; margin-bottom: 20rpx;"> item.orderStatus=='pay_failure'?'#F4506A':item.orderStatus=='pay_processing'?'#00D1FF':'#A1A0A8'">
<show-more> </card-header>
<key-value-row :keyName="i18n.USDTRate" :value="'19298'"></key-value-row> <view class="dataBody" v-if="form.type === 'online'">
<key-value-row :keyName="i18n.USDT" :value="'298237'"></key-value-row> <view style="padding:20rpx 32rpx;">
<view class="text">Postscript : ontact customer service on the top-left corner for identity <key-value-row :keyName="i18n.OrderID" :value="item.orderNo"></key-value-row>
verific <key-value-row :keyName="i18n.Fees" :value="(item.tranAmt-(parseInt(item.realAmount,16)))+item.coinCode"></key-value-row>
</view> <key-value-row :keyName="i18n.Time" :value="item.timestr"></key-value-row>
</show-more> </view>
</view> <view style="border-top: 2rpx solid #323045;padding:0rpx 32rpx; margin-bottom: 20rpx;">
<show-more>
</view> <key-value-row :keyName="i18n.USDTRate" :value="item.usdtRate"></key-value-row>
<key-value-row :keyName="i18n.USDT" :value="item.usdtAmount"></key-value-row>
</show-more>
</view>
</view>
</view> </view>
</view>
</view>
</view>
<u-empty :text="i18n.Dataisempty" mode="data" v-if="userInfoObj.length==0"></u-empty>
<u-loadmore :status="loadStatus" :loading-text="loadingText" :loadmore-text="loadmoreText"
:nomore-text="nomoreText" v-if="userInfoObj.length" height="80" />
</view>
</template> </template>
<script> <script>
import KeyValueRow from '../../components/KeyValueRow/KeyValueRow.vue'; import KeyValueRow from '../../components/KeyValueRow/KeyValueRow.vue';
import CardHeader from '../../components/cardHeader/cardHeader.vue'; import CardHeader from '../../components/cardHeader/cardHeader.vue';
import ShowMore from '../../components/showMore/showMore.vue'; import ShowMore from '../../components/showMore/showMore.vue';
export default { import constant from '@/utils/constant.js';
components: { KeyValueRow, CardHeader, ShowMore }, import api from '@/utils/api'
name: "rechargeRecord", export default {
data() { components: {
return { KeyValueRow,
pageState: 'coinRecharge', CardHeader,
}; ShowMore
}, },
computed: { name: "rechargeRecord",
i18n() { data() {
return this.$t("recharge"); return {
}, baseURL:'',
}, pageState: 'coinRecharge',
onLoad() { isLoadMore: false, //
}, loadStatus: 'loadmore',
onShow() { }, loadingText: this.$t("login").toload,
methods: { loadmoreText: this.$t("login").pullup,
change(e) { nomoreText: this.$t("login").Nomore,
console.log(e); form: {
} pageNumber: 1,
pageSize: 20,
}, type:'crypto',
} },
userInfoObj: [],
};
},
computed: {
i18n() {
return this.$t("recharge");
},
},
onReachBottom() {
if (!this.isLoadMore) {
this.form.pageNumber += 1
this.getList();
}
},
onLoad() {
this.baseURL = constant.BASE_URL
this.getList()
},
onShow() {},
methods: {
change(e) {
console.log(e);
},
getList() {
this.isLoadMore = true
api.rechargeList(this.form).then(res => {
if (res.content.length) {
if (this.form.pageNumber > 1) {
this.userInfoObj = this.userInfoObj.concat(res.content)
for (var i = 0; i < this.userInfoObj.length; i++) {
if (this.userInfoObj[i].addTime) {
this.userInfoObj[i].timestr = this.$index.formatyymmddhhmmss(this.userInfoObj[
i].addTime)
}
}
} else {
this.userInfoObj = res.content
for (var i = 0; i < this.userInfoObj.length; i++) {
if (this.userInfoObj[i].addTime) {
this.userInfoObj[i].timestr = this.$index.formatyymmddhhmmss(this.userInfoObj[
i].addTime)
}
}
}
if (this.userInfoObj.length >= Number(res.totalElements)) { //
this.isLoadMore = true
this.loadStatus = 'nomore'
} else {
this.isLoadMore = false
}
} else {
this.isLoadMore = true
this.loadStatus = 'nomore'
this.userInfoObj = []
}
this.$forceUpdate()
})
},
},
}
</script> </script>
<style lang="scss" scoped> <style lang="scss" scoped>
.main { .main {
.head { .head {
margin-top: 200rpx; margin-top: 200rpx;
margin-left: 60rpx; margin-left: 60rpx;
width: 632rpx; width: 632rpx;
display: flex; display: flex;
justify-content: space-around; justify-content: space-around;
align-items: center; align-items: center;
padding: 48rpx 0; padding: 48rpx 0;
.headItem { .headItem {
width: 300rpx; width: 300rpx;
height: 68rpx; height: 68rpx;
line-height: 68rpx; line-height: 68rpx;
background: #211F32; background: #211F32;
border-radius: 16rpx; border-radius: 16rpx;
text-align: center; text-align: center;
font-size: 32rpx; font-size: 32rpx;
color: #A1A0A8; color: #A1A0A8;
&.select { &.select {
background: #00E8A2; background: #00E8A2;
color: #15141F; color: #15141F;
} }
} }
} }
.cardList { .cardList {
padding-bottom: 40rpx; padding-bottom: 40rpx;
.card { .card {
overflow: hidden; overflow: hidden;
background: #211F32; background: #211F32;
border-radius: 32rpx; border-radius: 32rpx;
margin: 0 32rpx 32rpx; margin: 0 32rpx 32rpx;
.dataBody { .dataBody {
box-sizing: border-box; box-sizing: border-box;
.text { .text {
margin-top: 20rpx; margin-top: 20rpx;
padding: 10rpx 16rpx; padding: 10rpx 16rpx;
background: #323045; background: #323045;
border-radius: 8rpx; border-radius: 8rpx;
font-size: 24rpx; font-size: 24rpx;
color: #A1A0A8; color: #A1A0A8;
} }
} }
} }
} }
} }
</style> </style>

94
pages/withdrawal/addAddress.vue

@ -5,29 +5,29 @@
<view class="body"> <view class="body">
<!-- coin选择框 --> <!-- coin选择框 -->
<view class="choose-item"> <view class="choose-item">
<u-input class="input" v-model="coin" color="#fff" fontSize="32rpx" border="none" <u-input class="input" v-model="coinInfo.coinCode" color="#fff" fontSize="32rpx" border="none"
:placeholder="i18n.PleaseChooseCoin"> :placeholder="i18n.PleaseChooseCoin">
</u-input> </u-input>
<view class="selectCoinBtn" @click="USDTPopupShow = true">USDT <view class="selectCoinBtn" @click="USDTPopupShow = true">{{coinInfo.coinCode}}
</view> </view>
</view> </view>
<view class="addressBody"> <view class="addressBody">
<view class="address-title">{{ i18n.Address }}</view> <view class="address-title">{{ i18n.Address }}</view>
<view class="input-item"> <view class="input-item">
<u-input class="input" v-model="address" color="#fff" fontSize="32rpx" border="none" <u-input class="input" v-model="coinInfo.address" color="#fff" fontSize="32rpx" border="none"
:placeholder="i18n.enterAddressTips"> :placeholder="i18n.enterAddressTips">
</u-input> </u-input>
</view> </view>
<view class="address-title">{{ i18n.Remarks }}</view> <view class="address-title">{{ i18n.Remarks }}</view>
<view class="input-item"> <view class="input-item">
<u-input class="input" v-model="remarks" color="#fff" fontSize="32rpx" border="none" <u-input class="input" v-model="coinInfo.remarks" color="#fff" fontSize="32rpx" border="none"
:placeholder="i18n.enterRemarksTips"> :placeholder="i18n.enterRemarksTips">
</u-input> </u-input>
</view> </view>
</view> </view>
<u-button class="button" color="#00E8A2" throttleTime="500" :disabled="btnIsCanClick">{{ i18n.Confirm }} <u-button class="button" color="#00E8A2" throttleTime="500" :disabled="btnIsCanClick" @click="save">{{ i18n.Confirm }}
</u-button> </u-button>
<!-- USDT按钮通知弹出层 --> <!-- USDT按钮通知弹出层 -->
@ -37,17 +37,18 @@
<view class="close" @click="USDTPopupShow = false"></view> <view class="close" @click="USDTPopupShow = false"></view>
<scroll-view scroll-y="true" style="height: 432rpx;" scroll-with-animation="true" @touchmove.stop.prevent=""> <scroll-view scroll-y="true" style="height: 432rpx;" scroll-with-animation="true" @touchmove.stop.prevent="">
<radio-group class="radioGroup" @change="USDTRadioChange" v-model="USDTRadioValue"> <radio-group class="radioGroup" @change="USDTRadioChange" v-model="USDTRadioValue">
<label class="checkBox" v-for="(item, index) in 10" :key="index"> <label class="checkBox" v-for="(item, index) in withdrawInfo.coins" :key="index"
<view class="icon"> @click="radioChange(item)">
<u-icon name="../../static/maskets/logo.png" size="64rpx" width="64rpx"></u-icon> <view class="icon">
</view> <u-icon :name="baseURL+'/coins/'+item.code+'.png'" size="52rpx" width="52rpx">
<view class="iconName"> </u-icon>
<view class="top">USDT</view> </view>
<view class="bottom">BTC</view> <view class="iconName">
</view> <view class="top">{{item.enname}}</view>
<view class="bottom">{{item.useCapital}}{{" "}}{{item.code}}</view>
<radio color="#00E8A2" shape="square"></radio> </view>
</label> <radio color="#00E8A2" shape="square" :checked="coinInfo.coinCode==item.enname"></radio>
</label>
</radio-group> </radio-group>
</scroll-view> </scroll-view>
@ -67,14 +68,25 @@
<script> <script>
import uniCopy from '@/utils/uni-copy' import uniCopy from '@/utils/uni-copy'
import KeyValueRow from '../../components/KeyValueRow/KeyValueRow.vue'; import KeyValueRow from '../../components/KeyValueRow/KeyValueRow.vue';
import api from '@/utils/api'
import constant from '@/utils/constant.js';
export default { export default {
components: { KeyValueRow }, components: { KeyValueRow },
name: "withdrawal", name: "withdrawal",
data() { data() {
return { return {
baseURL:'',
//
selectCoinInfo: {},
coinInfo: {
coinCode:null,
address:null,
remarks:null,
},
//
withdrawInfo: {},
coin: '', coin: '',
address: '', address: '',
address: '',
USDTRadioValue: '', USDTRadioValue: '',
USDTPopupShow: false, USDTPopupShow: false,
@ -85,7 +97,7 @@ export default {
return this.$t("withdrawal"); return this.$t("withdrawal");
}, },
btnIsCanClick() { // btnIsCanClick() { //
if (this.coin && this.address && this.address) { if (this.coinInfo.coinCode && this.coinInfo.address && this.coinInfo.remarks) {
return false; // return false; //
}else{ }else{
return true return true
@ -93,6 +105,8 @@ export default {
} }
}, },
onLoad() { onLoad() {
this.baseURL = constant.BASE_URL
this.getWithConfig()
// //
uni.$on('coinAddressChang', (data) => { uni.$on('coinAddressChang', (data) => {
this.coinAddress = data.coinAddress this.coinAddress = data.coinAddress
@ -104,6 +118,45 @@ export default {
}, },
onShow() { }, onShow() { },
methods: { methods: {
//
save(){
api.withdrawAddressAdd({
coinCode:this.coinInfo.coinCode2,
address:this.coinInfo.address,
remarks:this.coinInfo.remarks,
}).then(res => {
uni.$u.toast(this.$t("login").Savesucceeded)
setTimeout(()=>{
this.coinInfo={
coinCode:null,
address:null,
remarks:null,
coinCode2:null,
}
},1200)
})
},
//
radioChange(e) {
this.selectCoinInfo = e
this.coinInfo.coinCode = e.enname
this.coinInfo.coinCode2 = e.code
},
//
getWithConfig() {
api.withdrawConfig({
type: 'crypto'
}).then(res => {
if (res) {
//
this.withdrawInfo = res
this.coinInfo.coinCode = this.withdrawInfo.coins[0].enname
this.coinInfo.coinCode2 = this.withdrawInfo.coins[0].code
}
})
},
goto(page) { goto(page) {
// console.log(page); // console.log(page);
let url = ''; let url = '';
@ -189,10 +242,9 @@ export default {
.selectCoinBtn { .selectCoinBtn {
position: absolute; position: absolute;
width: 170rpx;
height: 54rpx; height: 54rpx;
top: 36rpx; top: 36rpx;
right: 32rpx; right: 80rpx;
line-height: 56rpx; line-height: 56rpx;
font-size: 36rpx; font-size: 36rpx;
padding: 0; padding: 0;
@ -208,7 +260,7 @@ export default {
width: 32rpx; width: 32rpx;
height: 32rpx; height: 32rpx;
top: 12rpx; top: 12rpx;
right: 10rpx; right: -50rpx;
} }
} }

612
pages/withdrawal/chooseAddress.vue

@ -1,289 +1,361 @@
<template> <template>
<view class="main"> <view class="main">
<!-- nav --> <!-- nav -->
<navigation>{{ i18n.ChooseAddress }}<view slot="right" class="right" @click="editFlag = !editFlag;">{{ <navigation>{{ i18n.ChooseAddress }}
<view slot="right" class="right" @click="editFlag = !editFlag;">{{
editFlag ? i18n.OK : i18n.Edit editFlag ? i18n.OK : i18n.Edit
}} }}
</view> </view>
</navigation> </navigation>
<view class="content"> <view class="content">
<view class="message-item"> <view class="message-item">
{{ i18n.message4 }} {{ i18n.message4 }}
</view> </view>
<view class="message-item last"> <view class="message-item last">
{{ i18n.message5 }} {{ i18n.message5 }}
</view> </view>
<view class="card" v-if="coinList.length > 0"> <view class="card" v-if="userInfoObj.length > 0">
<view class="dataBody" v-for="(item, index) in 4" :key="index"> <view class="dataBody" v-for="(item, index) in userInfoObj" :key="index">
<view class="coinTitle">USDT</view> <view class="coinTitle">{{item.coinEnname}}</view>
<view class="addressItem" v-for="(addressItem, addressIndex) in 2" :key="addressIndex" <!-- v-for="(addressItem, addressIndex) in 2" :key="addressIndex" -->
@click="itemClick(index, addressIndex)"> <view class="addressItem"
<view class="radio" @click="itemClick(index, item)">
:class="{ select: (editCoinIndex === index && editCoinAddressIndex === addressIndex) }" <view class="radio"
v-if="editFlag"></view> :class="{ select: (editCoinIndex === index && editCoinAddressIndex === item.id) }"
<view class="addressInfo"> v-if="editFlag"></view>
<view class="addressTitle">{{ i18n.myOmniAddress }}</view> <view class="addressInfo">
<view class="address">SDIHJSD9809U9ERF9IOU0980970</view> <view class="addressTitle">{{ i18n.myOmniAddress }}</view>
<view class="time">2022/08/06 14:50:34</view> <view class="address">{{item.address}}</view>
</view> <view class="time">{{item.timestr}}</view>
</view>
</view>
</view> </view>
</view> </view>
<!-- 确认框 --> </view>
<u-modal :show="modalShow" :confirmText="i18n.OK" :cancelText="i18n.Cancel" :showCancelButton="true" <u-empty :text="i18n.Dataisempty" mode="data" v-if="userInfoObj.length==0"></u-empty>
:title="i18n.WarmTips" :content='i18n.WarmTipsText' @confirm="deleteAddress" @cancel="modalShow = false" <u-loadmore :status="loadStatus" :loading-text="loadingText" :loadmore-text="loadmoreText"
confirmColor="#00E8A2"> :nomore-text="nomoreText" v-if="userInfoObj.length" height="80" />
</u-modal> <!-- 确认框 -->
<!-- 编辑按钮 --> <u-modal :show="modalShow" :confirmText="i18n.OK" :cancelText="i18n.Cancel" :showCancelButton="true"
<view class="buttonBg"> :title="i18n.WarmTips" :content='i18n.WarmTipsText' @confirm="deleteAddress" @cancel="modalShow = false"
<u-button class="button" :color="editFlag ? '#F4506A' : '#00E8A2'" throttleTime="500" @click="btnClick" confirmColor="#00E8A2" cancelColor="#96959E">
:disabled="btnIsCanClick"> </u-modal>
{{ editFlag ? i18n.DeleteAddress : i18n.AddAddress }} <!-- 编辑按钮 -->
</u-button> <view class="buttonBg">
</view> <u-button class="button" :color="editFlag ? '#F4506A' : '#00E8A2'" throttleTime="500" @click="btnClick"
:disabled="btnIsCanClick">
</view> {{ editFlag ? i18n.DeleteAddress : i18n.AddAddress }}
</u-button>
</view> </view>
</view>
</view>
</template> </template>
<script> <script>
import KeyValueRow from '../../components/KeyValueRow/KeyValueRow.vue'; import KeyValueRow from '../../components/KeyValueRow/KeyValueRow.vue';
export default { import api from '@/utils/api'
components: { KeyValueRow }, import constant from '@/utils/constant.js';
name: "chooseAddress", export default {
data() { components: {
return { KeyValueRow
coinList: [{}], },
coinAddressList: [{}], name: "chooseAddress",
editFlag: false, // data() {
editCoinIndex: '', return {
editCoinAddressIndex: '', coinList: [{}],
coinAddress: 'SDIHJSD9809U9ERF9IOU0980970', coinAddressList: [{}],
currentCoin: 'USDT', editFlag: false, //
modalShow: false, editCoinIndex: '',
editCoinAddressIndex: '',
}; coinAddress: 'SDIHJSD9809U9ERF9IOU0980970',
}, currentCoin: 'USDT',
computed: { modalShow: false,
i18n() {
return this.$t("withdrawal"); isLoadMore: false, //
}, loadStatus: 'loadmore',
btnIsCanClick() { // loadingText: this.$t("login").toload,
if (this.editFlag) { loadmoreText: this.$t("login").pullup,
// console.log(`${this.editCoinIndex}` ? false : true); nomoreText: this.$t("login").Nomore,
return `${this.editCoinIndex}` ? false : true; // , form: {
} else { pageNumber: 1,
return false; // pageSize: 20,
} type: 'crypto',
} },
}, userInfoObj: [],
onLoad() {
};
}, },
onShow() { }, computed: {
methods: { i18n() {
itemClick(index, addressIndex) { return this.$t("withdrawal");
// },
if (this.editFlag) { btnIsCanClick() { //
// console.log(index, addressIndex); if (this.editFlag) {
if (this.editCoinIndex === index && this.editCoinAddressIndex === addressIndex) { // // console.log(`${this.editCoinIndex}` ? false : true);
this.editCoinIndex = ''; return `${this.editCoinIndex}` ? false : true; // ,
this.editCoinAddressIndex = ''; } else {
} else { // return false; //
this.editCoinIndex = index; }
this.editCoinAddressIndex = addressIndex; }
} },
} else { onLoad() {
// vuex },
uni.$emit('coinAddressChang', { onShow() {
coinAddress: this.coinAddress, this.getList()
}); },
uni.navigateBack() methods: {
getList() {
} this.isLoadMore = true
api.withdrawAddressList(this.form).then(res => {
}, if (res.content.length) {
btnClick() { if (this.form.pageNumber > 1) {
// this.userInfoObj = this.userInfoObj.concat(res.content)
if (this.editFlag) { for (var i = 0; i < this.userInfoObj.length; i++) {
this.modalShow = true if (this.userInfoObj[i].addTime) {
} else { this.userInfoObj[i].timestr = this.$index.formatyymmddhhmmss(this.userInfoObj[
// i].addTime)
uni.navigateTo({ }
url : '/pages/withdrawal/addAddress' }
}); } else {
} this.userInfoObj = res.content
}, for (var i = 0; i < this.userInfoObj.length; i++) {
if (this.userInfoObj[i].addTime) {
deleteAddress() { this.userInfoObj[i].timestr = this.$index.formatyymmddhhmmss(this.userInfoObj[
this.modalShow = false; i].addTime)
console.log('deleteAddress'); }
}, }
}
}, if (this.userInfoObj.length >= Number(res.totalElements)) { //
} this.isLoadMore = true
this.loadStatus = 'nomore'
} else {
this.isLoadMore = false
}
} else {
this.isLoadMore = true
this.loadStatus = 'nomore'
this.userInfoObj = []
}
this.$forceUpdate()
})
},
itemClick(index, addressIndex) {
console.log(index, addressIndex)
//
if (this.editFlag) {
// console.log(index, addressIndex);
if (this.editCoinIndex === index && this.editCoinAddressIndex === addressIndex.id) { //
this.editCoinIndex = '';
this.editCoinAddressIndex = '';
} else { //
this.editCoinIndex = index;
this.editCoinAddressIndex = addressIndex.id;
}
} else {
// vuex
uni.$emit('coinAddressChang', {
coinid: addressIndex.id,
coinAddress: addressIndex.address,
});
uni.navigateBack()
}
},
btnClick() {
//
if (this.editFlag) {
this.modalShow = true
} else {
//
uni.navigateTo({
url: '/pages/withdrawal/addAddress'
});
}
},
deleteAddress() {
this.modalShow = false;
//
api.withdrawAddressDel({
addressId:this.editCoinAddressIndex,
}).then(res => {
uni.$u.toast(this.$t("login").Deletesucceeded)
setTimeout(()=>{
this.getList()
},600)
})
},
},
}
</script> </script>
<style lang="scss" scoped> <style lang="scss" scoped>
.main { /deep/ .u-modal__content__text{
color: #96959E;
.right { }
width: 82rpx; .main {
height: 56rpx;
line-height: 56rpx; .right {
position: absolute; width: 82rpx;
right: 32rpx; height: 56rpx;
font-size: 24rpx; line-height: 56rpx;
background: rgba(246, 166, 9, 0.1); position: absolute;
border-radius: 8px; right: 32rpx;
color: #FFBC1F; font-size: 24rpx;
} background: rgba(246, 166, 9, 0.1);
border-radius: 8px;
color: #FFBC1F;
.content { }
margin-top: 200rpx;
padding: 40rpx;
.content {
.message-item { margin-top: 200rpx;
padding: 0 16rpx; padding: 40rpx;
font-size: 24rpx;
color: #A1A0A8; .message-item {
line-height: 36rpx; padding: 0 16rpx;
font-size: 24rpx;
&.last { color: #A1A0A8;
margin-bottom: 30rpx; line-height: 36rpx;
}
} &.last {
margin-bottom: 30rpx;
}
.card { }
.dataBody {
margin-bottom: 32rpx; .card {
padding: 32rpx;
box-sizing: border-box; .dataBody {
background: #211F32; margin-bottom: 32rpx;
border-radius: 20rpx; padding: 32rpx;
box-sizing: border-box;
.coinTitle { background: #211F32;
font-size: 24rpx; border-radius: 20rpx;
line-height: 28rpx;
margin-bottom: 32rpx; .coinTitle {
} font-size: 24rpx;
line-height: 28rpx;
.addressItem { margin-bottom: 32rpx;
height: 180rpx; }
box-sizing: border-box;
padding: 32rpx 0; .addressItem {
border-top: 2rpx solid #323045; flex: 0 1 50%;
display: flex; height: 180rpx;
box-sizing: border-box;
.radio { padding: 32rpx 0;
margin-top: 32rpx; border-top: 2rpx solid #323045;
margin-right: 24rpx; display: flex;
box-sizing: border-box;
width: 48rpx; .radio {
height: 48rpx; margin-top: 32rpx;
background: #323045; margin-right: 24rpx;
border: 3rpx solid #DCDBE0; box-sizing: border-box;
border-radius: 16rpx; width: 48rpx;
height: 48rpx;
background: #323045;
&.select { border: 3rpx solid #DCDBE0;
background-image: url(../../static/withdrawal/Checkbox_pr.png); border-radius: 16rpx;
background-repeat: no-repeat;
background-size: 48rpx;
border: none; &.select {
} background-image: url(../../static/withdrawal/Checkbox_pr.png);
} background-repeat: no-repeat;
background-size: 48rpx;
.addressInfo { border: none;
flex: 1; }
}
.addressTitle {
position: relative; .addressInfo {
font-size: 24rpx; width: 590rpx;
margin-bottom: 20rpx; .addressTitle {
position: relative;
&::after { font-size: 24rpx;
display: block; margin-bottom: 20rpx;
position: absolute;
content: ''; &::after {
background-image: url(../../static/charity/ic_ma_arrow_down.png); display: block;
background-repeat: no-repeat; position: absolute;
background-size: 32rpx; content: '';
width: 32rpx; background-image: url(../../static/charity/ic_ma_arrow_down.png);
height: 32rpx; background-repeat: no-repeat;
top: 0rpx; background-size: 32rpx;
right: 0rpx; width: 32rpx;
transform: rotate(270deg); height: 32rpx;
} top: 0rpx;
} right: 0rpx;
transform: rotate(270deg);
.address { }
font-size: 24rpx; }
line-height: 28rpx;
color: #A1A0A8; .address {
} font-size: 24rpx;
line-height: 28rpx;
.time { color: #A1A0A8;
font-size: 24rpx; word-break: break-all;
line-height: 28rpx; }
color: #A1A0A8;
} .time {
} font-size: 24rpx;
} line-height: 28rpx;
color: #A1A0A8;
}
}
}
&:last-child { &:last-child {
margin-bottom: 160rpx; margin-bottom: 160rpx;
} }
}
}
/deep/.u-popup__content {
background: #323045;
.u-modal__title {
color: #fff;
}
.u-modal__content__text {
text-align: center;
}
}
.buttonBg {
position: fixed;
bottom: 0rpx;
background-color: #15141F;
.button {
width: 670rpx;
box-sizing: border-box;
height: 112rpx;
margin-bottom: 40rpx;
border-radius: 32rpx;
font-weight: 700;
font-size: 32rpx;
color: #15141F !important;
}
}
}
}
/deep/.u-popup__content {
background: #323045;
.u-modal__title {
color: #fff;
}
.u-modal__content__text {
text-align: center;
}
}
.buttonBg {
position: fixed;
bottom: 0rpx;
background-color: #15141F;
.button { }
width: 670rpx;
box-sizing: border-box;
height: 112rpx;
margin-bottom: 40rpx;
border-radius: 32rpx;
font-weight: 700;
font-size: 32rpx;
color: #15141F !important;
}
}
}
}
}
</style> </style>

1470
pages/withdrawal/withdrawal.vue

File diff suppressed because it is too large

401
pages/withdrawal/withdrawalRecord.vue

@ -1,172 +1,245 @@
<template> <template>
<view class="main"> <view class="main">
<!-- nav --> <!-- nav -->
<navigation>{{ i18n.WithdrawalRecord }}</navigation> <navigation>{{ i18n.WithdrawalRecord }}</navigation>
<!-- headBtn --> <!-- headBtn -->
<view class="head"> <view class="head">
<view class="headItem" @click="pageState = 'digitalCurrency'" <view class="headItem" @click="form.type = 'crypto',getList()"
:class="{ select: pageState === 'digitalCurrency' }"> :class="{ select: form.type === 'crypto' }">
{{ i18n.DigitalCurrency }} {{ i18n.DigitalCurrency }}
</view> </view>
<view class="headItem" @click="pageState = 'onLine'" :class="{ select: pageState === 'onLine' }"> <view class="headItem" @click="form.type = 'online',getList()" :class="{ select:form.type=== 'online' }">
{{ i18n.OnLine }} {{ i18n.OnLine }}
</view> </view>
</view> </view>
<view class="cardList"> <view class="cardList">
<view class="card" v-for="(item, index) in 4" :key="index"> <view class="card" v-for="(item, index) in userInfoObj" :key="index">
<!-- 卡片条件渲染 --> <!-- 卡片条件渲染 -->
<!-- balance --> <!-- balance -->
<card-header v-if="pageState === 'digitalCurrency'" iconName="../../static/withdrawal/money-send.png" <card-header v-if="form.type === 'crypto'" :iconName="baseURL+'/coins/'+item.coinCode+'.png'"
:title="'904.29483230ACTA'" rightName="Succeed" fontColor="#00E8A2"> :title="item.tranAmt+item.coinCode"
</card-header> :rightName="item.orderStatus=='processreview'?'Underreview':item.orderStatus=='processsuccess'?'Success':
<view class="dataBody" v-if="pageState === 'digitalCurrency'"> item.orderStatus=='processing'?'Processing':item.orderStatus=='processfailed'?'Failed':'Failed'"
<view style="padding:20rpx 32rpx;"> :fontColor="item.orderStatus=='processreview'?'#F2FE8D':item.orderStatus=='processsuccess'?'#00E8A2':
<key-value-row :keyName="i18n.OrderID" :value="'293829773920223873676'"></key-value-row> item.orderStatus=='processfailed'?'#F4506A':item.orderStatus=='processing'?'#00D1FF':'#A1A0A8'">
<key-value-row :keyName="i18n.Fees" :value="'10.0922'"></key-value-row> </card-header>
<key-value-row :keyName="i18n.Time" :value="'2022/08/06 14:50:34'"></key-value-row> <view class="dataBody" v-if="form.type === 'crypto'">
</view> <view style="padding:20rpx 32rpx;">
<view style="border-top: 2rpx solid #323045;padding:0rpx 32rpx; margin-bottom: 20rpx;"> <key-value-row :keyName="i18n.OrderID" :value="item.orderNo"></key-value-row>
<show-more class="digitalShowMore"> <key-value-row :keyName="i18n.Fees" :value="item.tranFee"></key-value-row>
<key-value-row :keyName="i18n.Address" :value="'dhiukyfdhi8797979870800'"></key-value-row> <key-value-row :keyName="i18n.Time" :value="item.addTimeStr"></key-value-row>
<key-value-row :keyName="i18n.Hash" :value="'dhiukyfdhi8797979870800'"></key-value-row> </view>
<view class="text">Postscript : ontact customer service on the top-left corner for identity <view style="border-top: 2rpx solid #323045;padding:0rpx 32rpx; margin-bottom: 20rpx;">
verific <show-more class="digitalShowMore">
</view> <key-value-row :keyName="i18n.Address" :value="item.toAddress"></key-value-row>
</show-more> <key-value-row :keyName="i18n.Hash" :value="item.txid"></key-value-row>
</view> <!-- <view class="text">Postscript : ontact customer service on the top-left corner for identity
verific
</view> </view> -->
</show-more>
</view>
<!-- contarct -->
<card-header v-if="pageState === 'onLine'" iconName="../../static/withdrawal/money-send.png" </view>
:title="'904.29483230ACTA'" rightName="Succeed" fontColor="#00E8A2">
</card-header>
<view class="dataBody" v-if="pageState === 'onLine'"> <!-- contarct -->
<view style="padding:20rpx 32rpx;"> <!-- <card-header v-if="form.type === 'online'" iconName="../../static/withdrawal/money-send.png"
<key-value-row :keyName="i18n.OrderID" :value="'293829773920223873676'"></key-value-row> :title="'904.29483230ACTA'" rightName="Succeed" fontColor="#00E8A2">
<key-value-row :keyName="i18n.Fees" :value="'10.0922'"></key-value-row> </card-header> -->
<key-value-row :keyName="i18n.Time" :value="'2022/08/06 14:50:34'"></key-value-row> <card-header v-if="form.type === 'crypto'" iconName="../../static/withdrawal/money-send.png"
</view> :title="item.tranAmt+item.coinCode"
<show-more class="onLineShowMore" style="border-top: 2rpx solid #323045;margin-bottom: 20rpx;"> :rightName="item.orderStatus=='processreview'?'Underreview':item.orderStatus=='processsuccess'?'Success':
<view style="padding:20rpx 32rpx;"> item.orderStatus=='processing'?'Processing':item.orderStatus=='processfailed'?'Failed':'Failed'"
<key-value-row :keyName="i18n.USDTRate" :value="'19298'"></key-value-row> :fontColor="item.orderStatus=='processreview'?'#F2FE8D':item.orderStatus=='processsuccess'?'#00E8A2':
<key-value-row :keyName="i18n.USDT" :value="'298237'"></key-value-row> item.orderStatus=='processfailed'?'#F4506A':item.orderStatus=='processing'?'#00D1FF':'#A1A0A8'">
</view> </card-header>
<view style="border-top: 2rpx solid #323045;padding:20rpx 32rpx;"> <view class="dataBody" v-if="form.type === 'online'">
<key-value-row :keyName="i18n.CardNo" :value="'4349 9545 9893 9854 027'"> <view style="padding:20rpx 32rpx;">
</key-value-row> <key-value-row :keyName="i18n.OrderID" :value="item.orderNo"></key-value-row>
<key-value-row :keyName="i18n.Bank" :value="'Bank of Melbourne'"></key-value-row> <key-value-row :keyName="i18n.Fees" :value="item.tranFee"></key-value-row>
<key-value-row :keyName="i18n.Payee" :value="'Zhou jielun'"></key-value-row> <key-value-row :keyName="i18n.Time" :value="item.addTimeStr"></key-value-row>
<view class="text">Postscript ontact customer service on the top-left corner for identity </view>
verific <show-more class="onLineShowMore" style="border-top: 2rpx solid #323045;margin-bottom: 20rpx;">
</view> <view style="padding:20rpx 32rpx;">
</view> <key-value-row :keyName="i18n.USDTRate" :value="item.usdtRate"></key-value-row>
</show-more> <!-- -->
<key-value-row :keyName="i18n.USDT" :value="parseInt(item.channelAmount,16)"></key-value-row>
</view> </view>
<view style="border-top: 2rpx solid #323045;padding:20rpx 32rpx;">
<key-value-row :keyName="i18n.CardNo" :value="item.acctId">
</key-value-row>
</view> <key-value-row :keyName="i18n.Bank" :value="item.bankName"></key-value-row>
</view> <key-value-row :keyName="i18n.Payee" :value="item.acctName"></key-value-row>
</view> <!-- <view class="text">Postscript ontact customer service on the top-left corner for identity
verific
</view> -->
</view>
</show-more>
</view>
</view>
<u-empty :text="i18n.Dataisempty" mode="data" v-if="userInfoObj.length==0"></u-empty>
<u-loadmore :status="loadStatus" :loading-text="loadingText" :loadmore-text="loadmoreText"
:nomore-text="nomoreText" v-if="userInfoObj.length" height="80" />
</view>
</view>
</template> </template>
<script> <script>
import KeyValueRow from '../../components/KeyValueRow/KeyValueRow.vue'; import KeyValueRow from '../../components/KeyValueRow/KeyValueRow.vue';
import CardHeader from '../../components/cardHeader/cardHeader.vue'; import CardHeader from '../../components/cardHeader/cardHeader.vue';
import ShowMore from '../../components/showMore/showMore.vue'; import ShowMore from '../../components/showMore/showMore.vue';
export default { import constant from '@/utils/constant.js';
components: { KeyValueRow, CardHeader, ShowMore }, import api from '@/utils/api'
name: "withdrawalRecord", export default {
data() { components: {
return { KeyValueRow,
pageState: 'digitalCurrency', CardHeader,
}; ShowMore
}, },
computed: { name: "withdrawalRecord",
i18n() { data() {
return this.$t("withdrawal"); return {
}, pageState: 'digitalCurrency',
}, baseURL: '',
onLoad() { isLoadMore: false, //
}, loadStatus: 'loadmore',
onShow() { }, loadingText: this.$t("login").toload,
methods: { loadmoreText: this.$t("login").pullup,
change(e) { nomoreText: this.$t("login").Nomore,
console.log(e); form: {
} pageNumber: 1,
pageSize: 20,
}, type: 'crypto',
} },
userInfoObj: [],
};
},
computed: {
i18n() {
return this.$t("withdrawal");
},
},
onReachBottom() {
if (!this.isLoadMore) {
this.form.pageNumber += 1
this.getList();
}
},
onLoad() {
this.baseURL = constant.BASE_URL
this.getList()
},
onShow() {},
methods: {
getList() {
this.isLoadMore = true
api.withdrawList(this.form).then(res => {
if (res.content.length) {
if (this.form.pageNumber > 1) {
this.userInfoObj = this.userInfoObj.concat(res.content)
for (var i = 0; i < this.userInfoObj.length; i++) {
if (this.userInfoObj[i].addTime) {
this.userInfoObj[i].timestr = this.$index.formatyymmddhhmmss(this.userInfoObj[
i].addTime)
}
}
} else {
this.userInfoObj = res.content
for (var i = 0; i < this.userInfoObj.length; i++) {
if (this.userInfoObj[i].addTime) {
this.userInfoObj[i].timestr = this.$index.formatyymmddhhmmss(this.userInfoObj[
i].addTime)
}
}
}
if (this.userInfoObj.length >= Number(res.totalElements)) { //
this.isLoadMore = true
this.loadStatus = 'nomore'
} else {
this.isLoadMore = false
}
} else {
this.isLoadMore = true
this.loadStatus = 'nomore'
this.userInfoObj = []
}
this.$forceUpdate()
})
},
change(e) {
console.log(e);
}
},
}
</script> </script>
<style lang="scss" scoped> <style lang="scss" scoped>
.main { .main {
.head { .head {
margin-top: 200rpx; margin-top: 200rpx;
margin-left: 60rpx; margin-left: 60rpx;
width: 632rpx; width: 632rpx;
display: flex; display: flex;
justify-content: space-around; justify-content: space-around;
align-items: center; align-items: center;
padding: 48rpx 0; padding: 48rpx 0;
.headItem { .headItem {
width: 300rpx; width: 300rpx;
height: 68rpx; height: 68rpx;
line-height: 68rpx; line-height: 68rpx;
background: #211F32; background: #211F32;
border-radius: 16rpx; border-radius: 16rpx;
text-align: center; text-align: center;
font-size: 32rpx; font-size: 32rpx;
color: #A1A0A8; color: #A1A0A8;
&.select { &.select {
background: #00E8A2; background: #00E8A2;
color: #15141F; color: #15141F;
} }
} }
} }
.cardList { .cardList {
padding-bottom: 40rpx; padding-bottom: 40rpx;
.card { .card {
overflow: hidden; overflow: hidden;
background: #211F32; background: #211F32;
border-radius: 32rpx; border-radius: 32rpx;
margin: 0 32rpx 32rpx; margin: 0 32rpx 32rpx;
.dataBody { .dataBody {
box-sizing: border-box; box-sizing: border-box;
.onLineShowMore { .onLineShowMore {
/deep/.showMoreTool { /deep/.showMoreTool {
margin: 0 32rpx; margin: 0 32rpx;
} }
} }
.text { .text {
margin-top: 20rpx; margin-top: 20rpx;
padding: 10rpx 16rpx; padding: 10rpx 16rpx;
background: #323045; background: #323045;
border-radius: 8rpx; border-radius: 8rpx;
font-size: 24rpx; font-size: 24rpx;
color: #A1A0A8; color: #A1A0A8;
} }
} }
} }
} }
} }
</style> </style>

7
utils/language/en_US.js

@ -10,6 +10,11 @@ export default {
}, },
// 登陆相关页面 // 登陆相关页面
login: { login: {
Withdrawalsucceeded:'Withdrawal succeeded',
Deletesucceeded:'Delete succeeded',
Savesucceeded:'Saved successfully',
Rechargesucceeded:'Recharge succeeded',
Transfersucceeded:'Transfer succeeded',
Donationsucceeded:'Donation succeeded', Donationsucceeded:'Donation succeeded',
Insufficient:'Insufficient available balance', Insufficient:'Insufficient available balance',
pullup:'Gently pull up', pullup:'Gently pull up',
@ -155,6 +160,7 @@ export default {
// recharge // recharge
recharge: { recharge: {
Dataisempty:'Data is empty',
Recharge: 'Recharge', Recharge: 'Recharge',
Record: 'Record', Record: 'Record',
CoinRecharge: 'Coin Recharge', CoinRecharge: 'Coin Recharge',
@ -216,6 +222,7 @@ export default {
// withdrawal // withdrawal
withdrawal: { withdrawal: {
Dataisempty:'Data is empty',
Withdrawal: 'Withdrawal', Withdrawal: 'Withdrawal',
Record: 'Record', Record: 'Record',
DigitalCurrency: 'Digital currency', DigitalCurrency: 'Digital currency',

1624
utils/qrCode/wxqrcode.js

File diff suppressed because it is too large
Loading…
Cancel
Save