You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

155 lines
3.3 KiB

This file contains ambiguous Unicode characters!

This file contains ambiguous Unicode characters that may be confused with others in your current locale. If your use case is intentional and legitimate, you can safely ignore this warning. Use the Escape button to highlight these characters.

<template>
<view class='cotainer'>
<view>
<!-- <u-empty v-if="dataList.length==0" marginTop="250"></u-empty> -->
<view class="orderlist">
<view class="orderlist-item">
<view>时间2023-11-02</view>
<view class="orderlist-item-date">
<view>
积分余额1000
</view>
<view>
兑换记录123
</view>
<view>
兑换增减:-1
</view>
</view>
<view class="orderlist-item-btn">
</view>
</view>
<view class="orderlist-item">
<view>时间2023-11-02</view>
<view class="orderlist-item-date">
<view>
积分余额1000
</view>
<view>
兑换记录123
</view>
<view>
兑换增减:-1
</view>
</view>
<view class="orderlist-item-btn">
</view>
</view>
</view>
</view>
</view>
</template>
<script>
export default {
components: {
},
data() {
return {
isLoading: false,
dataList: []
}
},
onLoad() {
// this.loadOrder(1)
},
onPullDownRefresh() {
if (!this.isLoading) {
this.loadOrder(this.currentPage + 1);
}
},
onReachBottom() {
if (!this.isLoading) {
this.loadOrder(this.currentPage + 1);
}
},
methods: {
todetail(id) {
// uni.navigateTo({
// url: "/pages/exhibit/detail?id=" + id
// });
},
loadOrder(page) {
uni.hideKeyboard()
var that = this;
that.isLoading = true;
// this.util.request({
// api: '/api/mobile/exhibit-hall/index',
// customLoading: false,
// data: {
// page: page,
// page_size: 6,
// state: this.tablist[this.current].idx,
// sort_name: 'state',
// sort_name_tow: 'release_time',
// sort_type: "DESC",
// sort_type_tow: 'DESC'
// },
// utilSuccess: function(r) {
// var res = r.data;
// that.isLoading = false;
// var hasNoMore = r.total < 6 && page > 1;
// console.log("hasNoMore", hasNoMore)
// if (hasNoMore || res.length == 0 && page > 1) {
// uni.stopPullDownRefresh(); // 服务器总条数 < 每页条数, 会将第一页的条数重新返回
// // 已加载到最后一页
// uni.showToast({
// title: '已加载到最后一页',
// icon: 'none'
// });
// return;
// }
// var dataList = that.dataList;
// for(var m of res){
// m.dateRange = that.util.splitTime(m.start_time,m.over_time)
// }
// if (page == 1) {
// dataList = res;
// } else {
// dataList.push(...res);
// }
// that.currentPage = page;
// that.dataList = dataList;
// },
// utilFail: function(res) {
// if (page == 1) {
// that.currentPage = page;
// }
// that.util.alert(res);
// }
// });
}
}
}
</script>
<style lang="scss">
.cotainer{
}
.orderlist {
padding: 0 30rpx;
padding-bottom: 150rpx;
&-item{
border:1px solid #ddd;
border-radius: 20rpx;
padding:30rpx;
margin:20rpx 0;
&-date{
padding-bottom:10rpx;
border-bottom:1px solid #ddd;
}
&-btn{
display: flex;
justify-content: space-between;
margin-top:30rpx;
}
}
}
</style>