|
|
@@ -13,7 +13,7 @@
|
|
|
<text class="padding-left-xs"
|
|
|
style="font-size: 24upx;font-family: PingFang SC;font-weight: 800;color: #878787;">热力值</text>
|
|
|
</view>
|
|
|
- <button class="cu-btn round text-white" style="background-color: #f75757;width: 140upx;">提现</button>
|
|
|
+ <button @click="doAwards" class="cu-btn round text-white" style="background-color: #f75757;width: 140upx;">提现</button>
|
|
|
</view>
|
|
|
<view style="margin: 10upx 20upx;">
|
|
|
<u-line color="#e0e0e0"></u-line>
|
|
|
@@ -34,17 +34,21 @@
|
|
|
<view class="cuIcon-text text-bold padding-right-xs" style="font-size: 38upx;"></view>
|
|
|
<view class="title">提现明细</view>
|
|
|
</view>
|
|
|
- <view v-for="(item, index) in list" :key="index" class="flex align-center justify-between">
|
|
|
+ <view v-for="(item, index) in list" :key="index" class="flex align-center justify-between padding-sm">
|
|
|
<view class="padding-lr">
|
|
|
<view class="title">{{item.note}}</view>
|
|
|
- <view style="font-size: 24upx;font-family: PingFang SC;font-weight: bold;color: #686868;">
|
|
|
+ <view class="padding-top-sm" style="font-size: 24upx;font-family: PingFang SC;font-weight: bold;color: #686868;">
|
|
|
{{item.createTime}}</view>
|
|
|
</view>
|
|
|
<view class="padding-right">
|
|
|
- <text style="font-size: 36upx;font-family: PingFang SC;font-weight: bold;color: #F3484E;">+{{ +item.hotValue}}</text>
|
|
|
+ <text style="font-size: 36upx;font-family: PingFang SC;font-weight: bold;color: #F3484E;">+{{ +item.cashValue}}</text>
|
|
|
<text class="text-bold padding-left-xs">元</text>
|
|
|
</view>
|
|
|
</view>
|
|
|
+ <view class="padding-top-sm">
|
|
|
+
|
|
|
+ </view>
|
|
|
+ <u-loadmore :status="status" />
|
|
|
<view style="padding: 20upx;">
|
|
|
<u-line color="#e0e0e0"></u-line>
|
|
|
</view>
|
|
|
@@ -59,14 +63,31 @@
|
|
|
return {
|
|
|
userId: '',
|
|
|
data: {},
|
|
|
- list:[]
|
|
|
+ list:[],
|
|
|
+
|
|
|
+ status: 'loadmore',
|
|
|
+ current:1
|
|
|
}
|
|
|
},
|
|
|
onLoad() {
|
|
|
- this.userId = uni.getStorageSync("userId") || -1;
|
|
|
+ this.userId = uni.getStorageSync("userId");
|
|
|
+ if (!this.userId) {
|
|
|
+ this.$u.toast('用户未登录')
|
|
|
+ return
|
|
|
+ }
|
|
|
this.getBonus()
|
|
|
- this.getList()
|
|
|
+ this.fetchData()
|
|
|
},
|
|
|
+ onReachBottom() {
|
|
|
+ if(this.list.length<this.current*10){
|
|
|
+ this.status = 'nomore';
|
|
|
+ return
|
|
|
+ }else{
|
|
|
+ this.status = 'loading';
|
|
|
+ this.current = ++ this.current;
|
|
|
+ this.fetchData()
|
|
|
+ }
|
|
|
+ },
|
|
|
methods: {
|
|
|
getBonus() {
|
|
|
this.$u.api.user.getBonus({
|
|
|
@@ -75,9 +96,19 @@
|
|
|
this.data = res
|
|
|
})
|
|
|
},
|
|
|
- getList() {
|
|
|
- this.$u.api.user.withdrawrecords({userId: this.userId}).then(res => {
|
|
|
- this.list = res.records
|
|
|
+ fetchData() {
|
|
|
+ let params={
|
|
|
+ size:10,
|
|
|
+ userId: this.userId,
|
|
|
+ current:this.current
|
|
|
+ }
|
|
|
+ this.$u.api.user.withdrawrecords(params).then(res => {
|
|
|
+ this.list = [...this.list,...res.records]
|
|
|
+ })
|
|
|
+ },
|
|
|
+ doAwards(){
|
|
|
+ uni.navigateTo({
|
|
|
+ url:"doAwards?userId="+this.userId
|
|
|
})
|
|
|
}
|
|
|
}
|