24 changed files with 1381 additions and 98 deletions
|
After Width: | Height: | Size: 385 B |
|
After Width: | Height: | Size: 1.9 KiB |
|
After Width: | Height: | Size: 611 B |
@ -1,8 +1,12 @@ |
|||
// 导入自己需要的组件
|
|||
import { Slider } from 'element-ui' |
|||
import { Slider,Collapse,CollapseItem } from 'element-ui' |
|||
const components = [Slider,Collapse,CollapseItem] |
|||
const element = { |
|||
install: function (Vue) { |
|||
Vue.use(Slider) |
|||
// Vue.use(Slider)
|
|||
components.forEach(component => { |
|||
Vue.use(component) |
|||
}) |
|||
} |
|||
} |
|||
export default element |
|||
@ -0,0 +1,194 @@ |
|||
<template> |
|||
<!-- <view style="padding: 40rpx 0px;"> |
|||
<scroll-view scroll-x="true" style="width: 340px;"> |
|||
<view style="width: 450px;"> |
|||
<table class="table"> |
|||
<thead> |
|||
<tr> |
|||
<th class="color1" style="width: 100rpx;">{{ $t("common.d8") }}</th> |
|||
<th class="color1">{{ $t("common.amout") }}</th> |
|||
<th class="color1" style="width: 150rpx;">{{ $t("common.d9") }}</th> |
|||
<th class="color1" style="width: 100rpx;">{{ $t("common.d10") }}</th> |
|||
<th class="color1" style="text-align: center;width: 180rpx;">{{ $t("common.d13") }}</th> |
|||
<th class="color1" style="text-align: center;width: 180rpx;">{{ $t("common.d15") }}</th> |
|||
</tr> |
|||
</thead> |
|||
<tbody> |
|||
<tr v-for="(item,index) in recordsList" :key="index" style="border-bottom: 1px solid #ccc;height: 140rpx;"> |
|||
<td style="text-align: center;">{{item.currency}}</td> |
|||
<td style="margin-right: 20rpx;">{{item.amount}}</td> |
|||
<td style="text-align: center;">{{item.rate}}%</td> |
|||
<td v-if="item.type==1" style="text-align: center;">{{$t('common.d17')}}</td> |
|||
<td v-if="item.type==2" style="text-align: center;">{{item.day}}{{$t('exchange.f0')}}</td> |
|||
<td style="text-align: center;">{{item.financial_time}}</td> |
|||
<td style="text-align: center;">{{item.redemption_time}}</td> |
|||
</tr> |
|||
</tbody> |
|||
</table> |
|||
</view> |
|||
</scroll-view> |
|||
</view> --> |
|||
<view style="background-color: #f9f9f9;height: 100%;color: #666;"> |
|||
<v-header class="nav-head" :title="$t('common.d7')"></v-header> |
|||
<scroll-view scroll-y="true" style="height: 90vh;"> |
|||
<view style="padding: 0rpx 40rpx;"> |
|||
<view v-for="(item,index) in recordsList" :key="index" class="recordsList_box"> |
|||
<view style="width: 160rpx;"> |
|||
<view>{{ $t("common.d8") }}</view> |
|||
<view>{{item.currency}}</view> |
|||
</view> |
|||
<view style="width: 200rpx;text-align: center;"> |
|||
<view>{{ $t("common.amout") }}</view> |
|||
<view>{{item.amount}}</view> |
|||
</view> |
|||
<view style="width: 200rpx;text-align: right;"> |
|||
<view>{{ $t("common.d9") }}</view> |
|||
<view>{{item.rate}}%</view> |
|||
</view> |
|||
<view style="width: 160rpx;margin-top: 30rpx;"> |
|||
<view>{{ $t("common.d10") }}</view> |
|||
<view v-if="item.type==1">{{$t('common.d17')}}</view> |
|||
<view v-if="item.type==2">{{item.day}}{{$t('exchange.f0')}}</view> |
|||
</view> |
|||
<view style="width: 200rpx;text-align: center;margin-top: 30rpx;"> |
|||
<view>{{ $t("common.d13") }}</view> |
|||
<view>{{item.financial_time}}</view> |
|||
</view> |
|||
<view style="width: 200rpx;text-align: right;margin-top: 30rpx;"> |
|||
<view>{{ $t("common.d15") }}</view> |
|||
<view>{{item.redemption_time}}</view> |
|||
</view> |
|||
</view> |
|||
</view> |
|||
</scroll-view> |
|||
</view> |
|||
</template> |
|||
|
|||
<script> |
|||
import Wallet from "@/api/wallet"; |
|||
export default { |
|||
name: "finances-product", |
|||
props: { |
|||
|
|||
}, |
|||
components: { |
|||
|
|||
}, |
|||
watch: { |
|||
|
|||
}, |
|||
created() { |
|||
this.init() |
|||
}, |
|||
data() { |
|||
return { |
|||
recordsList:[] |
|||
}; |
|||
}, |
|||
methods: { |
|||
init(){ |
|||
Wallet.financial_records({status:1}).then(res => { |
|||
this.recordsList = res.data.data; |
|||
console.log(this.recordsList); |
|||
}) |
|||
}, |
|||
} |
|||
}; |
|||
</script> |
|||
|
|||
<style scoped lang="scss"> |
|||
.color1{ |
|||
color: #908F94; |
|||
} |
|||
tbody tr:hover{ |
|||
background: #e9e9e9; |
|||
} |
|||
.jump_btn{ |
|||
display: inline-block; |
|||
min-width: 160rpx; |
|||
height: 70rpx; |
|||
line-height: 66rpx; |
|||
text-align: center; |
|||
border: 1px solid #444444; |
|||
border-radius: 100rpx; |
|||
font-size: 30rpx; |
|||
padding: 0px 40rpx; |
|||
font-weight: 400; |
|||
color: #000; |
|||
box-sizing: border-box; |
|||
|
|||
&:hover{ |
|||
cursor: pointer; |
|||
color: #67e2da; |
|||
border: 1px solid #67e2da; |
|||
} |
|||
} |
|||
.jump_btn1{ |
|||
display: inline-block; |
|||
min-width: 160rpx; |
|||
height: 70rpx; |
|||
line-height: 66rpx; |
|||
text-align: center; |
|||
color: #999999; |
|||
border: 1px solid #999999; |
|||
border-radius: 100rpx; |
|||
font-size: 30rpx; |
|||
padding: 0px 40rpx; |
|||
font-weight: 400; |
|||
box-sizing: border-box; |
|||
} |
|||
.tr_box{ |
|||
display: flex; |
|||
margin: 0px 20rpx; |
|||
line-height: 100rpx; |
|||
} |
|||
.collapse_box{ |
|||
width: 100%; |
|||
display: flex; |
|||
font-size: 30rpx; |
|||
font-weight: bold; |
|||
} |
|||
.collapse_box1{ |
|||
display: flex; |
|||
font-size: 30rpx; |
|||
font-weight: bold; |
|||
line-height: 100rpx; |
|||
align-items: center; |
|||
justify-content: space-between; |
|||
} |
|||
.collapse_box2{ |
|||
display: flex; |
|||
font-size: 30rpx; |
|||
line-height: 100rpx; |
|||
font-weight: bold; |
|||
align-items: center; |
|||
justify-content: space-between; |
|||
} |
|||
.currency_box{ |
|||
display: flex; |
|||
align-items: center; |
|||
padding:40rpx 0rpx 40rpx; |
|||
justify-content: space-between; |
|||
border-bottom: 1px solid #bcbcbc; |
|||
} |
|||
.box1{ |
|||
width: 26%; |
|||
padding-left: 5px; |
|||
} |
|||
.box2{ |
|||
width: 25%; |
|||
} |
|||
.box4{ |
|||
width: 20%; |
|||
text-align: right; |
|||
} |
|||
.recordsList_box{ |
|||
display: flex; |
|||
flex-wrap: wrap; |
|||
margin:40rpx 0px; |
|||
padding: 30rpx; |
|||
border-radius: 20rpx; |
|||
background-color: #fff; |
|||
justify-content: space-between; |
|||
} |
|||
</style> |
|||
@ -0,0 +1,334 @@ |
|||
<template> |
|||
<!-- <div style="padding: 40rpx 0px;"> |
|||
<scroll-view scroll-x="true" style="width: 340px;"> |
|||
<view style="width: 500px;"> |
|||
<table class="table"> |
|||
<thead> |
|||
<tr> |
|||
<th class="color1" style="width: 100rpx;">{{ $t("common.d8") }}</th> |
|||
<th class="color1">{{ $t("common.amout") }}</th> |
|||
<th class="color1" style="width: 150rpx;">{{ $t("common.d9") }}</th> |
|||
<th class="color1" style="width: 100rpx;">{{ $t("common.d10") }}</th> |
|||
<th class="color1" style="text-align: center;width: 200rpx;">{{ $t("common.d13") }}</th> |
|||
<th class="color1" style="text-align: right;width: 200rpx;">{{ $t("common.d11") }}</th> |
|||
</tr> |
|||
</thead> |
|||
<tbody> |
|||
<tr v-for="(item,index) in recordsList" :key="index" style="border-bottom: 1px solid #ccc;height: 140rpx;"> |
|||
<td style="text-align: center;">{{item.currency}}</td> |
|||
<td style="margin-right: 20rpx;">{{item.amount}}</td> |
|||
<td style="text-align: center;">{{item.rate}}%</td> |
|||
<td v-if="item.type==1" style="text-align: center;">{{$t('common.d17')}}</td> |
|||
<td v-if="item.type==2" style="text-align: center;">{{item.day}}{{$t('exchange.f0')}}</td> |
|||
<td style="text-align: center;">{{item.financial_time}}</td> |
|||
<td style="text-align: right;"> |
|||
<div class="jump_btn" v-if="item.type==1" data-toggle="modal" data-target="#editAddress" @click="Subscription(item)">{{$t('common.d14')}}</div> |
|||
<div class="jump_btn1" v-if="item.type==2">{{$t('common.d14')}}</div> |
|||
</td> |
|||
</tr> |
|||
</tbody> |
|||
</table> |
|||
</view> |
|||
</scroll-view> |
|||
|
|||
<van-popup :show="stopsubscription" @close="stopsubscription = false" closeable custom-style="height:auto;width:90%;overflow:auto;padding-bottom:20px;border-radius:5px"> |
|||
<view> |
|||
<view style="padding: 30rpx;border-bottom: 1px solid #ccc;">{{$t("common.d18")}}</view> |
|||
<view style="border-bottom: 1px solid #bcbcbc;"> |
|||
<view style="margin: 0px 30rpx;"> |
|||
<view class="currency_box"> |
|||
<view> |
|||
<view style="font-weight: bold;">{{subscriptionobj.currency}}</view> |
|||
<view style="display: flex;align-items: center;margin-top: 20rpx;" v-if="subscriptionobj.day"> |
|||
<img src="@/assets/img/hint.png" width="15" style="margin-right: 10rpx;" /> |
|||
{{$t('common.d20')}} |
|||
</view> |
|||
</view> |
|||
<view> |
|||
<view style="font-weight: bold;"> |
|||
<view v-if="subscriptionobj.day">{{subscriptionobj.day}}{{$t('exchange.f0')}}</view> |
|||
<view v-else> |
|||
{{$t('common.d17')}} |
|||
</view> |
|||
</view> |
|||
</view> |
|||
</view> |
|||
<view style="display: flex;justify-content: space-between;padding: 40rpx 0px;"> |
|||
<view style="color: #B4B4B4;font-weight: bold;">{{$t('common.d9')}}</view> |
|||
<view style="display: flex;align-items: center;"> |
|||
<view>{{subscriptionobj.rate}}%</view> |
|||
<view style="display: flex;align-items: center;margin-left: 10px;"><img src="@/assets/img/rise.png" width="18" /></view> |
|||
</view> |
|||
</view> |
|||
<view class="d-flex justify-between"> |
|||
<view>{{$t('assets.c0')}}</view> |
|||
<view>{{subscriptionobj.amount}} USDT</view> |
|||
</view> |
|||
<view class="d-flex justify-between" style="margin: 40rpx 0px;font-size:36rpx"> |
|||
<view>{{$t('common.d21')}}</view> |
|||
<view> |
|||
<span style="color: #7458A8;margin-right: 10rpx;">{{subscriptionobj.interest}}</span> |
|||
<span> USDT</span> |
|||
</view> |
|||
</view> |
|||
</view> |
|||
</view> |
|||
<view class="d-flex justify-around"> |
|||
<v-button class="m-t-md rounded-lg" style="width: 40%;" type="red" block @click="stopsubscription = false" ref="strateBtn"> |
|||
{{ $t("common.cancel") }} |
|||
</v-button> |
|||
<v-button class="m-t-md rounded-lg" style="width: 40%;" type="green" block @click="handleUserAddress" ref="strateBtn"> |
|||
{{ $t("common.confirm") }} |
|||
</v-button> |
|||
</view> |
|||
</view> |
|||
</van-popup> |
|||
</div> --> |
|||
<view> |
|||
<v-header class="nav-head" :title="$t('common.d14')"></v-header> |
|||
<view style="padding: 40rpx;color: #666;"> |
|||
<view class="d-flex"> |
|||
<view @click="bool1=1" :class="bool1==1?'col-border':''">{{$t('common.d17')}}</view> |
|||
<view @click="bool1=2" :class="bool1==2?'col-border':''" style="margin-left: 100rpx;">{{$t('common.d45')}}</view> |
|||
</view> |
|||
<view style="margin-top: 30rpx;font-size: 26rpx;">{{$t('common.d46')}}</view> |
|||
<scroll-view scroll-y="true" style="height: 75vh;"> |
|||
<view v-for="(item,index) in recordsList" :key="index" class="recordsList_box" v-if="bool1==1"> |
|||
<view style="width: 160rpx;"> |
|||
<view>{{ $t("common.d8") }}</view> |
|||
<view>{{item.currency}}</view> |
|||
</view> |
|||
<view style="width: 160rpx;text-align: center;"> |
|||
<view>{{ $t("common.amout") }}</view> |
|||
<view>{{item.amount}}</view> |
|||
</view> |
|||
<view style="width: 200rpx;text-align: right;"> |
|||
<view>{{ $t("common.d9") }}</view> |
|||
<view>{{item.rate}}%</view> |
|||
</view> |
|||
<view style="width: 160rpx;margin-top: 30rpx;"> |
|||
<view>{{ $t("option.a4") }}</view> |
|||
<view>{{item.yield_rate}}%</view> |
|||
</view> |
|||
<view style="width: 160rpx;margin-top: 30rpx;text-align: center;"> |
|||
<view>{{ $t('common.d21') }}</view> |
|||
<view>{{item.interest}}</view> |
|||
</view> |
|||
<view style="width: 200rpx;text-align: right;margin-top: 30rpx;"> |
|||
<view>{{ $t("common.d13") }}</view> |
|||
<view>{{item.financial_time}}</view> |
|||
</view> |
|||
<view style="width: 100%;text-align: right;margin-top: 30rpx;"> |
|||
<view></view> |
|||
<view> |
|||
<div class="jump_btn" data-toggle="modal" data-target="#editAddress" @click="Subscription(item)">{{$t('common.d14')}}</div> |
|||
</view> |
|||
</view> |
|||
</view> |
|||
<view v-for="(item,index) in recordsList1" :key="index" class="recordsList_box" v-if="bool1==2"> |
|||
<view style="width: 160rpx;"> |
|||
<view>{{ $t("common.d8") }}</view> |
|||
<view>{{item.currency}}</view> |
|||
</view> |
|||
<view style="width: 160rpx;text-align: center;"> |
|||
<view>{{ $t("common.amout") }}</view> |
|||
<view>{{item.amount}}</view> |
|||
</view> |
|||
<view style="width: 200rpx;text-align: right;"> |
|||
<view>{{ $t("common.d9") }}</view> |
|||
<view>{{item.rate}}%</view> |
|||
</view> |
|||
<view style="width: 160rpx;margin-top: 30rpx;"> |
|||
<view>{{$t('common.d21')}}</view> |
|||
<view> |
|||
<span style="color: #7458A8;margin-right: 10rpx;">{{item.interest}}</span> |
|||
<!-- <span> USDT</span> --> |
|||
</view> |
|||
</view> |
|||
<view style="width: 160rpx;margin-top: 30rpx;text-align: center;"> |
|||
<view>{{ $t("common.d10") }}</view> |
|||
<view v-if="item.type==1" style="text-align: center;">{{$t('common.d17')}}</view> |
|||
<view v-if="item.type==2" style="text-align: center;">{{item.day}}{{$t('exchange.f0')}}</view> |
|||
</view> |
|||
<view style="width: 200rpx;text-align: right;margin-top: 30rpx;"> |
|||
<view>{{ $t("common.d13") }}</view> |
|||
<view>{{item.financial_time}}</view> |
|||
</view> |
|||
<view style="width: 100%;text-align: right;margin-top: 30rpx;"> |
|||
<view></view> |
|||
<view> |
|||
<div class="jump_btn" data-toggle="modal" data-target="#editAddress" @click="Subscription(item)">{{$t('common.d14')}}</div> |
|||
</view> |
|||
</view> |
|||
</view> |
|||
</scroll-view> |
|||
</view> |
|||
</view> |
|||
</template> |
|||
|
|||
<script> |
|||
import Wallet from "@/api/wallet"; |
|||
export default { |
|||
name: "finances-product", |
|||
props: { |
|||
|
|||
}, |
|||
components: { |
|||
|
|||
}, |
|||
watch: { |
|||
|
|||
}, |
|||
created() { |
|||
this.init() |
|||
this.getBalance() |
|||
}, |
|||
data() { |
|||
return { |
|||
recordsList:[], |
|||
recordsList1:[], |
|||
subscriptionobj:{}, |
|||
coin_name:"USDT", |
|||
activeCoin:{}, |
|||
amount:0, |
|||
bool1:1, |
|||
stopsubscription:false |
|||
}; |
|||
}, |
|||
methods: { |
|||
init(){ |
|||
Wallet.financial_records({status:0}).then(res => { |
|||
this.recordsList = res.data.data.filter(item => item.type === 1); |
|||
this.recordsList1 = res.data.data.filter(item => item.type === 2); |
|||
}) |
|||
}, |
|||
Subscription(data){ |
|||
this.subscriptionobj = data; |
|||
this.handleUserAddress() |
|||
// console.log(this.subscriptionobj); |
|||
}, |
|||
handleUserAddress() { |
|||
const data = { |
|||
id: this.subscriptionobj.id |
|||
} |
|||
Wallet.financial_redemption(data).then(res => { |
|||
// console.log(res); |
|||
if(res.code==200){ |
|||
this.$toast(this.$t("common.success")); |
|||
this.stopsubscription = false; |
|||
this.init() |
|||
this.getBalance(); |
|||
} |
|||
}); |
|||
}, |
|||
getBalance(){ |
|||
let data = { |
|||
account: 4, |
|||
coin_name: this.coin_name |
|||
}; |
|||
Wallet.getBalance(data).then(res => { |
|||
this.activeCoin = res; |
|||
// console.log(res); |
|||
}); |
|||
} |
|||
} |
|||
}; |
|||
</script> |
|||
|
|||
<style scoped lang="scss"> |
|||
.color1{ |
|||
color: #908F94; |
|||
} |
|||
tbody tr:hover{ |
|||
background: #e9e9e9; |
|||
} |
|||
.jump_btn{ |
|||
display: inline-block; |
|||
// min-width: 160rpx; |
|||
min-width: 100%; |
|||
height: 60rpx; |
|||
line-height: 56rpx; |
|||
text-align: center; |
|||
border: 1px solid #67e2da; |
|||
border-radius: 100rpx; |
|||
font-size: 30rpx; |
|||
padding: 0px 40rpx; |
|||
font-weight: 400; |
|||
color: #67e2da; |
|||
margin-top: 20rpx; |
|||
box-sizing: border-box; |
|||
} |
|||
.jump_btn1{ |
|||
display: inline-block; |
|||
min-width: 160rpx; |
|||
height: 60rpx; |
|||
line-height: 56rpx; |
|||
text-align: center; |
|||
color: #999999; |
|||
border: 1px solid #999999; |
|||
border-radius: 100rpx; |
|||
font-size: 30rpx; |
|||
padding: 0px 40rpx; |
|||
font-weight: 400; |
|||
margin-top: 20rpx; |
|||
box-sizing: border-box; |
|||
} |
|||
.tr_box{ |
|||
display: flex; |
|||
margin: 0px 20rpx; |
|||
line-height: 100rpx; |
|||
} |
|||
.collapse_box{ |
|||
width: 100%; |
|||
display: flex; |
|||
font-size: 30rpx; |
|||
font-weight: bold; |
|||
} |
|||
.collapse_box1{ |
|||
display: flex; |
|||
font-size: 30rpx; |
|||
font-weight: bold; |
|||
line-height: 100rpx; |
|||
align-items: center; |
|||
justify-content: space-between; |
|||
} |
|||
.collapse_box2{ |
|||
display: flex; |
|||
font-size: 30rpx; |
|||
line-height: 100rpx; |
|||
font-weight: bold; |
|||
align-items: center; |
|||
justify-content: space-between; |
|||
} |
|||
.currency_box{ |
|||
display: flex; |
|||
align-items: center; |
|||
padding:40rpx 0rpx 40rpx; |
|||
justify-content: space-between; |
|||
border-bottom: 1px solid #bcbcbc; |
|||
} |
|||
.box1{ |
|||
width: 26%; |
|||
padding-left: 5px; |
|||
} |
|||
.box2{ |
|||
width: 25%; |
|||
} |
|||
.box4{ |
|||
width: 20%; |
|||
text-align: right; |
|||
} |
|||
.col-border{ |
|||
color: #4097f4; |
|||
border-bottom: 2px solid #4097f4; |
|||
} |
|||
.recordsList_box{ |
|||
display: flex; |
|||
flex-wrap: wrap; |
|||
margin:40rpx 0px; |
|||
padding: 30rpx; |
|||
border-radius: 20rpx; |
|||
background-color: #f9f9f9; |
|||
justify-content: space-between; |
|||
} |
|||
</style> |
|||
@ -0,0 +1,369 @@ |
|||
<template> |
|||
<!-- <div> |
|||
<table class="w-max"> |
|||
<thead> |
|||
<tr class="tr_box"> |
|||
<div class="color1" style="width: 25%;">{{ $t("common.d8") }}</div> |
|||
<div class="color1" style="width: 25%;">{{ $t("common.d9") }}</div> |
|||
<div class="color1" style="width: 25%;text-align: center;">{{ $t("common.d10") }}</div> |
|||
<div class="color1" style="width: 25%;text-align: right;">{{ $t("common.d11") }}</div> |
|||
</tr> |
|||
</thead> |
|||
<tbody> |
|||
<el-collapse accordion> |
|||
<el-collapse-item v-for="(item,index) in userAdressList" :key="index"> |
|||
<div slot="title" class="collapse_box"> |
|||
<div class="box1">{{item.coin_name}}</div> |
|||
<div class="box2">{{item.rate}}%</div> |
|||
<div style="width: 27%;">{{$t('common.d16')}}</div> |
|||
<div class="box4"></div> |
|||
</div> |
|||
<div class="collapse_box1"> |
|||
<div class="box1"></div> |
|||
<div class="box2">{{item.rate}}%</div> |
|||
<div style="width: 31%;">{{$t('common.d17')}}</div> |
|||
<div class="box4"> |
|||
<div class="jump_btn" data-toggle="modal" data-target="#editAddress" |
|||
@click="Subscription({rate:item.rate,coin_name:item.coin_name,index:1,coin_id:item.coin_id})">{{$t('common.d12')}}</div> |
|||
</div> |
|||
</div> |
|||
<div v-for="(items,indexs) in item.params" :key="indexs" class="collapse_box2"> |
|||
<div class="box1"> </div> |
|||
<div class="box2">{{items.fixed_rate}}%</div> |
|||
<div style="width: 31%;">{{items.day}}{{$t('exchange.f0')}}</div> |
|||
<div class="box4"> |
|||
<div class="jump_btn" data-toggle="modal" data-target="#editAddress" |
|||
@click="Subscription1({...items,coin_name:item.coin_name,coin_id:item.coin_id})">{{$t('common.d12')}}</div> |
|||
</div> |
|||
</div> |
|||
</el-collapse-item> |
|||
</el-collapse> |
|||
</tbody> |
|||
</table> |
|||
|
|||
<van-popup :show="stopsubscription" @close="stopsubscription = false" closeable custom-style="height:auto;width:90%;overflow:auto;padding-bottom:20px;border-radius:5px"> |
|||
<view> |
|||
<view style="padding: 30rpx;border-bottom: 1px solid #ccc;">{{$t("common.d18")}}</view> |
|||
<view style="border-bottom: 1px solid #bcbcbc;"> |
|||
<view style="margin: 0px 30rpx;"> |
|||
<view style="display: flex;align-items: center;justify-content: space-between;border-bottom: 1px solid #bcbcbc;padding:40rpx 0rpx 40rpx;"> |
|||
<view> |
|||
<view style="font-weight: bold;">{{subscriptionobj.coin_name}}</view> |
|||
<view style="display: flex;align-items: center;margin-top: 20rpx;" v-if="subscriptionobj.day"> |
|||
<img src="@/assets/img/hint.png" width="15" style="margin-right: 10rpx;" /> |
|||
{{$t('common.d20')}} |
|||
</view> |
|||
</view> |
|||
<view> |
|||
<view style="font-weight: bold;"> |
|||
<view v-if="subscriptionobj.day">{{subscriptionobj.day}}{{$t('exchange.f0')}}</view> |
|||
<view v-else> |
|||
{{$t('common.d17')}} |
|||
</view> |
|||
</view> |
|||
</view> |
|||
</view> |
|||
<view style="display: flex;justify-content: space-between;padding: 40rpx 0px;"> |
|||
<view style="color: #B4B4B4;font-weight: bold;">{{$t('common.d9')}}</view> |
|||
<view style="display: flex;align-items: center;"> |
|||
<view>{{subscriptionobj.rate}}%</view> |
|||
<view style="display: flex;align-items: center;margin-left: 10px;"><img src="@/assets/img/rise.png" width="18" /></view> |
|||
</view> |
|||
</view> |
|||
<view> |
|||
<view>{{$t('assets.c0')}}</view> |
|||
<view style="margin-top: 20rpx;"> |
|||
<v-input v-model="amount" class="h-50 p-x-sm p-y-xxs color-light bg-form-panel-3" :placeholder="$t('exchange.c5')"> |
|||
<template #right> |
|||
<view class="color-default color-light">USDT</view> |
|||
</template> |
|||
</v-input> |
|||
</view> |
|||
</view> |
|||
<view style="margin: 40rpx 0px;"> |
|||
<span style="margin-right: 20rpx;">{{$t('common.d22')}}</span> |
|||
<span>{{activeCoin.usable_balance}} USDT</span> |
|||
</view> |
|||
</view> |
|||
</view> |
|||
<view class="d-flex justify-around"> |
|||
<v-button class="m-t-md rounded-lg" style="width: 40%;" type="red" block @click="stopsubscription = false" ref="strateBtn"> |
|||
{{ $t("common.cancel") }} |
|||
</v-button> |
|||
<v-button class="m-t-md rounded-lg" style="width: 40%;" type="green" block @click="define" ref="strateBtn"> |
|||
{{ $t("common.confirm") }} |
|||
</v-button> |
|||
</view> |
|||
</view> |
|||
</van-popup> |
|||
</div> --> |
|||
<view> |
|||
<v-header class="nav-head" :title="$t('common.d12')"></v-header> |
|||
<view style="padding: 40rpx 40rpx;"> |
|||
<view class="d-flex" style="flex-wrap: wrap;" v-for="(item,index) in userAdressList" :key="index"> |
|||
<view class="ratebox" :class="Subscriptionindex==null?'Subscriptionbox':''" @click="Subscriptiontab({index:1,coin_id:item.coin_id})"> |
|||
<view>{{$t('common.d17')}}</view> |
|||
<view>{{item.rate}}%{{$t('exchange.e3')}}</view> |
|||
</view> |
|||
<view class="ratebox" v-for="(items,indexs) in item.params" @click="Subscriptiontab({...items,index:2,coin_id:item.coin_id,indexs1:indexs})" |
|||
:class="Subscriptionindex==indexs?'Subscriptionbox':''"> |
|||
<view>{{items.day}}{{$t('exchange.f0')}}</view> |
|||
<view>{{items.fixed_rate}}%{{$t('exchange.e3')}}</view> |
|||
</view> |
|||
</view> |
|||
<view style="margin-top: 40rpx;"> |
|||
<view>{{$t('common.d29')}}</view> |
|||
<view style="margin: 30rpx 0rpx;"> |
|||
<v-input v-model="amount" class="h-50 p-x-sm p-y-xxs color-light" style="border: 1px solid #ccc;border-radius: 20rpx;" :placeholder="$t('common.d30')"> |
|||
<template #right> |
|||
<view class="color-default color-light">USDT</view> |
|||
</template> |
|||
</v-input> |
|||
</view> |
|||
<view class="d-flex"> |
|||
<view>{{$t('common.d22')}}</view> |
|||
<view class="m-l-ms">{{activeCoin.usable_balance}} USDT</view> |
|||
<!-- <view class="m-l-lg" style="color: #b5b500;" @click="_router.push('/pages/transfer/index')">{{$t('common.d31')}}</view> --> |
|||
<view class="m-l-lg" style="color: #b5b500;" @click="_router.push(userinfo.primary_status!=1?'/pages/auth/index':'/pages/assets/recharge')">{{$t('common.d31')}}</view> |
|||
</view> |
|||
<view class="text1">{{$t('common.d32')}}<span style="color: #4097f4;">{{parseInt(amount/100)*20}}BXPE</span>{{$t('common.d33')}}</view> |
|||
<view style="font-size: 24rpx;"> |
|||
{{$t('common.d34')}}:<br /> |
|||
{{$t('common.d35')}}<br /> |
|||
{{$t('common.d36')}} |
|||
</view> |
|||
<view class="d-flex" style="margin: 40rpx 0rpx;"> |
|||
<view @click="bool1=1" style="margin-right: 80rpx;" :class="bool1==1?'col-border':''">{{$t('common.d37')}}</view> |
|||
<view @click="bool1=2" :class="bool1==2?'col-border':''">{{$t('common.d38')}}</view> |
|||
</view> |
|||
<view v-if="bool1==1"> |
|||
<view class="d-flex justify-between m-b-lg"> |
|||
<view>{{$t('common.d39')}}</view> |
|||
<view style="color: ##60c08c;">100.00USDT</view> |
|||
</view> |
|||
<view>{{$t('common.d40')}}</view> |
|||
</view> |
|||
<view v-if="bool1==2"> |
|||
<view> |
|||
<view>1、{{$t('common.d41')}}</view> |
|||
<view>{{$t('common.d42')}}</view> |
|||
</view> |
|||
<view> |
|||
<view>2、{{$t('common.d14')}}</view> |
|||
<view>{{$t('common.d43')}}</view> |
|||
</view> |
|||
</view> |
|||
</view> |
|||
<view style="background-color: #fff;height: 150rpx;position: fixed;bottom: 0rpx;display: flex;align-items: center;"> |
|||
<view class="bottom_box" @click="define">{{$t('auth.b3')}}</view> |
|||
</view> |
|||
</view> |
|||
<view style="height: 136rpx;"></view> |
|||
</view> |
|||
</template> |
|||
|
|||
<script> |
|||
import Wallet from "@/api/wallet"; |
|||
export default { |
|||
name: "finances-product", |
|||
props: { |
|||
|
|||
}, |
|||
components: { |
|||
|
|||
}, |
|||
computed: { |
|||
|
|||
}, |
|||
watch: { |
|||
|
|||
}, |
|||
created() { |
|||
this.init() |
|||
this.getBalance() |
|||
}, |
|||
data() { |
|||
return { |
|||
userAdressList:[], |
|||
subscriptionobj:{ |
|||
coin_id:1, |
|||
index:1 |
|||
}, |
|||
coin_name:"USDT", |
|||
activeCoin:{}, |
|||
amount:null, |
|||
bool1:1, |
|||
stopsubscription:false, |
|||
Subscriptionindex:null, |
|||
userinfo:uni.getStorageSync("user") |
|||
}; |
|||
}, |
|||
methods: { |
|||
init(){ |
|||
Wallet.activity().then(res => { |
|||
this.userAdressList = res.data; |
|||
// console.log(this.userAdressList); |
|||
}) |
|||
}, |
|||
// Subscription(data){ |
|||
// this.subscriptionobj = data; |
|||
// this.stopsubscription = true |
|||
// // console.log(this.subscriptionobj); |
|||
// }, |
|||
// Subscription1(data){ |
|||
// data.index = 2; |
|||
// data.rate = data.fixed_rate; |
|||
// // data.coin_name = 2; |
|||
// this.subscriptionobj = data; |
|||
// this.stopsubscription = true |
|||
// // console.log(this.subscriptionobj); |
|||
// }, |
|||
Subscriptiontab(data){ |
|||
if(data.index==1){ |
|||
this.Subscriptionindex = null; |
|||
this.subscriptionobj = data; |
|||
}else{ |
|||
this.Subscriptionindex = data.indexs1; |
|||
this.subscriptionobj = data; |
|||
} |
|||
|
|||
}, |
|||
define() { |
|||
const data = { |
|||
amount: this.amount, |
|||
coin_id: this.subscriptionobj.coin_id, |
|||
type: this.subscriptionobj.index, |
|||
day: this.subscriptionobj.day?this.subscriptionobj.day:'' |
|||
} |
|||
// console.log(data); |
|||
Wallet.financialNow(data).then(res => { |
|||
// console.log(res); |
|||
if(res.code==200){ |
|||
this.amount = ''; |
|||
this.$toast(this.$t("common.success")); |
|||
this.getBalance(); |
|||
} |
|||
}); |
|||
}, |
|||
getBalance(){ |
|||
let data = { |
|||
account: 4, |
|||
coin_name: this.coin_name |
|||
}; |
|||
Wallet.getBalance(data).then(res => { |
|||
this.activeCoin = res.data; |
|||
// console.log(res); |
|||
}); |
|||
} |
|||
} |
|||
}; |
|||
</script> |
|||
<style> |
|||
|
|||
</style> |
|||
<style scoped lang="scss"> |
|||
::v-deep .el-collapse-item__header{ |
|||
line-height: 15px !important; |
|||
} |
|||
::v-deep .collapse_box{ |
|||
align-items: center; |
|||
} |
|||
.color1{ |
|||
color: #908F94; |
|||
} |
|||
tbody tr:hover{ |
|||
background: #e9e9e9; |
|||
} |
|||
.jump_btn{ |
|||
display: inline-block; |
|||
min-width: 80px; |
|||
height: 35px; |
|||
line-height: 33px; |
|||
text-align: center; |
|||
color: #fff; |
|||
border: 1px solid #444444; |
|||
border-radius: 50px; |
|||
font-size: 15px; |
|||
padding: 0px 20px; |
|||
font-weight: 400; |
|||
color: #000; |
|||
box-sizing: border-box; |
|||
} |
|||
.tr_box{ |
|||
display: flex; |
|||
margin: 0px 10px; |
|||
padding: 40rpx 0px; |
|||
// line-height: 50px; |
|||
} |
|||
.collapse_box{ |
|||
width: 100%; |
|||
display: flex; |
|||
font-size: 15px; |
|||
font-weight: bold; |
|||
} |
|||
.collapse_box1{ |
|||
padding: 20rpx 0px; |
|||
display: flex; |
|||
font-size: 15px; |
|||
font-weight: bold; |
|||
line-height: 15px; |
|||
align-items: center; |
|||
justify-content: space-between; |
|||
} |
|||
.collapse_box2{ |
|||
padding: 20rpx 0px; |
|||
display: flex; |
|||
font-size: 15px; |
|||
// line-height: 50px; |
|||
font-weight: bold; |
|||
align-items: center; |
|||
justify-content: space-between; |
|||
} |
|||
.box1{ |
|||
width: 26%; |
|||
padding-left: 5px; |
|||
} |
|||
.box2{ |
|||
width: 25%; |
|||
} |
|||
.box4{ |
|||
width: 40%; |
|||
text-align: right; |
|||
} |
|||
.ratebox{ |
|||
width: 150rpx; |
|||
padding: 20rpx; |
|||
font-size: 25rpx; |
|||
margin-top: 20rpx; |
|||
margin-right: 28rpx; |
|||
border-radius: 10rpx; |
|||
border: 1px solid #757575; |
|||
} |
|||
.text1{ |
|||
font-size: 34rpx; |
|||
font-weight: bold; |
|||
text-align: center; |
|||
padding: 30rpx 0rpx; |
|||
border-bottom: 2px solid #ccc; |
|||
} |
|||
.col-border{ |
|||
color: #4097f4; |
|||
border-bottom: 2px solid #4097f4; |
|||
} |
|||
.bottom_box{ |
|||
color: #fff; |
|||
width: 660rpx; |
|||
height: 80rpx; |
|||
text-align: center; |
|||
line-height: 80rpx; |
|||
background-color: #585f69; |
|||
} |
|||
.Subscriptionbox{ |
|||
width: 150rpx; |
|||
color: #4097f4; |
|||
padding: 20rpx; |
|||
font-size: 25rpx; |
|||
border-radius: 10rpx; |
|||
border: 1px solid #4097f4; |
|||
} |
|||
</style> |
|||
@ -0,0 +1,124 @@ |
|||
<template> |
|||
<v-page> |
|||
<v-header class="nav-head" :left-arrow="false" :title="$t('common.d1')"> |
|||
<template #right> |
|||
<v-link to="/pages/financialManagement/finances-history"> |
|||
<van-icon class="fn-20 m-t-xs" name="todo-list-o" /> |
|||
</v-link> |
|||
</template> |
|||
</v-header> |
|||
<main class="" style="padding: 40rpx;"> |
|||
<view class="d-flex"> |
|||
<view>{{$t('common.d23')}}</view> |
|||
<view style="margin-left: 10rpx;"><img src="@/assets/img/home/user.png" width="20" /></view> |
|||
</view> |
|||
<view class="d-block color-light" style="margin-top: 5px;"> |
|||
<span class="fn-20 m-r-xs">{{ activeCoin.usable_balance }}</span> |
|||
<span> USDT</span> |
|||
</view> |
|||
<view class="bg-form-panel-3 activeCoinAmount"> |
|||
<view> |
|||
<view style="text-align: center;">{{$t('common.d24')}}</view> |
|||
<view style="width: 130rpx;word-break: break-word;text-align: center;">$ {{activeCoin.yesterdayAmount}}</view> |
|||
</view> |
|||
<view> |
|||
<view style="text-align: center;">{{$t('common.d25')}}</view> |
|||
<view style="width: 130rpx;word-break: break-word;text-align: center;">$ {{activeCoin.businessAmount}}</view> |
|||
</view> |
|||
<view> |
|||
<view style="text-align: center;">{{$t('common.d26')}}</view> |
|||
<view style="width: 130rpx;word-break: break-word;text-align: center;">$ {{activeCoin.totalAmount}}</view> |
|||
</view> |
|||
</view> |
|||
<view class="d-flex justify-around" style="margin: 60rpx 0px;"> |
|||
<view style="color: #4097f4;border-bottom: 2px solid #4097f4;padding-bottom: 10rpx;">{{$t('common.d12')}}</view> |
|||
<view @click="onredemption">{{$t('common.d14')}}</view> |
|||
</view> |
|||
<view v-for="(item,index) in userAdressList" style="border-bottom: 2px solid #ebebeb;padding-bottom: 30rpx;" @click="toproduct"> |
|||
<view class="d-flex" style="font-size: 36rpx;font-weight: bold;"> |
|||
<view><img src="https://bbxr.bxrcos.com/storage/coin_icon/USDT.png" width="25" /></view> |
|||
<view style="margin-left: 20rpx;">{{item.coin_name}}</view> |
|||
</view> |
|||
<view class="d-flex justify-between"> |
|||
<view>{{$t("common.d9")}}</view> |
|||
<view style="color: #60c08c;">{{item.rate}}%{{$t('exchange.e3')}}</view> |
|||
</view> |
|||
<view class="d-flex justify-between"> |
|||
<view>{{$t("common.d10")}}</view> |
|||
<view>{{$t('common.d16')}}</view> |
|||
</view> |
|||
<view class="d-flex justify-between"> |
|||
<view>{{$t("common.d44")}}</view> |
|||
<view style="color: #4097f4;">{{item.cumulativeIncome}}</view> |
|||
</view> |
|||
</view> |
|||
</main> |
|||
</v-page> |
|||
</template> |
|||
|
|||
<script> |
|||
import Wallet from "@/api/wallet"; |
|||
export default { |
|||
name: "index", |
|||
components: { |
|||
|
|||
}, |
|||
created() { |
|||
this.getBalance() |
|||
this.init() |
|||
}, |
|||
data() { |
|||
return { |
|||
activeCoin:{}, |
|||
userAdressList:[], |
|||
coin_name1:"USDT", |
|||
}; |
|||
}, |
|||
watch:{ |
|||
'$route' (to, from){ |
|||
this.getBalance() |
|||
// console.log(to.fullPath); |
|||
// console.log(from); |
|||
} |
|||
}, |
|||
methods: { |
|||
getBalance(){ |
|||
let data = { |
|||
account: 4, |
|||
coin_name: this.coin_name1 |
|||
}; |
|||
Wallet.getBalance(data).then(res => { |
|||
this.activeCoin = res.data; |
|||
// console.log(res); |
|||
}); |
|||
}, |
|||
init(){ |
|||
Wallet.activity().then(res => { |
|||
this.userAdressList = res.data; |
|||
// console.log(this.userAdressList); |
|||
}) |
|||
}, |
|||
onredemption(){ |
|||
uni.navigateTo({ |
|||
url:'/pages/financialManagement/finances-hold' |
|||
}) |
|||
}, |
|||
toproduct(){ |
|||
uni.navigateTo({ |
|||
url:'/pages/financialManagement/finances-product' |
|||
}) |
|||
} |
|||
} |
|||
}; |
|||
</script> |
|||
|
|||
<style scoped lang="scss"> |
|||
.activeCoinAmount{ |
|||
display: flex; |
|||
margin-top: 30rpx; |
|||
font-weight: bold; |
|||
border-radius: 20rpx; |
|||
padding: 30rpx 40rpx; |
|||
justify-content: space-between; |
|||
} |
|||
</style> |
|||
@ -0,0 +1,22 @@ |
|||
<template> |
|||
<view> |
|||
<web-view src="https://bbxr.bxrcos.com/storage/poster/user-1-1.jpg"></web-view> |
|||
</view> |
|||
</template> |
|||
|
|||
<script> |
|||
export default { |
|||
data() { |
|||
return { |
|||
|
|||
} |
|||
}, |
|||
methods: { |
|||
|
|||
} |
|||
} |
|||
</script> |
|||
|
|||
<style> |
|||
|
|||
</style> |
|||
|
After Width: | Height: | Size: 1.6 KiB |
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
Loading…
Reference in new issue