新增充值记录板块

This commit is contained in:
weipengfei 2023-07-25 14:41:50 +08:00
parent bf843c0f79
commit 3a81410fff
5 changed files with 174 additions and 4 deletions

View File

@ -162,7 +162,16 @@
"navigationBarTitleText": "账户充值",
"enablePullDownRefresh": false,
"navigationBarBackgroundColor": "#3175f9",
"navigationBarTextStyle": "white"
"navigationBarTextStyle": "white",
"app-plus": {
"titleNView": {
"buttons": [{
"color": "#fff",
"text": "充值记录",
"fontSize": "15"
}]
}
}
}
}, {
@ -263,6 +272,15 @@
"navigationBarTextStyle": "white"
}
}, {
"path": "topUpList/topUpList",
"style": {
"navigationBarTitleText": "充值记录",
"enablePullDownRefresh": false,
"navigationBarBackgroundColor": "#3175f9",
"navigationBarTextStyle": "white"
}
}]
}],
"globalStyle": {

View File

@ -36,7 +36,7 @@
getCopyOfMyListAPI
} from '@/api/oaApi.js'
import { Toast } from '@/libs/uniApi.js'
// import tabbar from '../components/tabbar'
export default {
components: {
@ -116,8 +116,8 @@
}
},
click(item) {
Toast('开发中')
return
Toast('开发中')
return
this.myEventList = []
this.params.page = '1'
switch (item.index) {

View File

@ -57,6 +57,7 @@
if(this.loadConfig.status=="nomore")return;
this.loadConfig.status="loading"
const res = await noticeList({
sort: 'new',
keyword: this.searchText,
page_no: this.loadConfig.page,
page_size: this.loadConfig.limit

View File

@ -44,6 +44,14 @@
timeCount: 5,
}
},
//
onNavigationBarButtonTap(res){
if (res.index === 0) {
uni.navigateTo({
url: '/subpkg/topUpList/topUpList'
})
}
},
onLoad() {},
onShow() {},
methods: {

View File

@ -0,0 +1,143 @@
<template>
<view class="">
<view class="list">
<view class="card" v-for="(item, index) in list" :key="index">
<view class="top">
<view class="tips">余额充值</view>
<view>充值日期{{item.create_time}}</view>
</view>
<view class="bottom">
<view class="left">
<view>充值金额()</view>
<view class="num">{{item.order_amount}}</view>
</view>
<view class="right">
<view>备注:</view>
<view>{{item.tips}}</view>
</view>
</view>
</view>
</view>
<u-loadmore :status="loadConfig.status" :loading-text="loadConfig.loadingText" :loadmore-text="loadConfig.loadmoreText" :nomore-text="loadConfig.nomoreText" />
</view>
</template>
<script>
import {rechargeLists} from "@/api/pay.js"
export default {
data() {
return {
list:[],
loadConfig:{
page: 1,
limit: 15,
loadingText: '努力加载中',
loadmoreText: '轻轻上拉',
nomoreText: '没有更多记录了~~',
status: 'loadmore'
},
}
},
onLoad() {
this.loadList();
},
onShow() {},
onReachBottom() {
this.loadList()
},
methods: {
async loadList(){
if(this.loadConfig.status=="nomore")return;
this.loadConfig.status="loading"
let res = await rechargeLists({
page_no: this.loadConfig.page,
page_size: this.loadConfig.limit
});
this.loadConfig.status="loadmore"
if(res.data.lists.length<this.loadConfig.limit){
this.loadConfig.status="nomore"
}else {
this.loadConfig.page++;
}
this.list = [...this.list, ...res.data.lists];
}
},
onPullDownRefresh() {
uni.stopPullDownRefresh()
}
}
</script>
<style lang="scss">
.list{
// background-color: #f5f5f5;
display: flex;
flex-direction: column;
align-items: center;
padding-top: 28rpx;
.card{
padding: 28rpx;
width: 694rpx;
background-color: #fff;
margin-bottom: 21rpx;
.top{
display: flex;
align-items: center;
font-size: 25rpx;
font-weight: 400;
color: #333333FF;
line-height: 39rpx;
.tips{
width: 137rpx;
height: 49rpx;
background: #3274F9;
border-radius: 26rpx 26rpx 26rpx 26rpx;
font-size: 25rpx;
font-weight: 400;
color: #FFFFFF;
line-height: 39rpx;
display: flex;
justify-content: center;
align-items: center;
margin-right: 28rpx;
}
// .pass{
// background-color: #FF8C1A;
// }
// .no_pass{
// background-color: #F02828;
// }
// .ok{
// background-color: #47B347;
// }
}
.bottom{
display: flex;
justify-content: space-between;
align-items: center;
height: 160rpx;
.left{
flex: 1;
text-align: center;
font-size: 25rpx;
font-weight: 400;
color: #666666;
line-height: 39rpx;
.num{
font-size: 39rpx;
font-weight: 500;
color: #F02828;
line-height: 39rpx;
}
}
.right{
flex: 1;
font-size: 25rpx;
font-weight: 400;
color: #666666;
line-height: 39rpx;
}
}
}
}
</style>