Browse Source

feature-hub-1.0:修改权益页面错误

feature-1.0
penny 4 years ago
parent
commit
0e93e277b6
  1. 2
      .gitignore
  2. 148
      pages-userInfo/contact/contact.vue
  3. 19
      pages-userInfo/inviteLog/inviteLog.vue
  4. 17
      pages-userInfo/notice/notice.vue
  5. 19
      pages-userInfo/withdraw/withdraw.vue
  6. 85
      pages/profit/profitEndDetails.vue
  7. 85
      pages/profit/profitInDetails.vue
  8. 64
      pages/profit/profitPreDetails.vue

2
.gitignore

@ -1,2 +1,4 @@
/node_modules/ /node_modules/
/unpackage/ /unpackage/
/.idea/
/.hbuilderx/

148
pages-userInfo/contact/contact.vue

@ -1,106 +1,60 @@
<template> <template>
<view class="container"> <view class="container">
我是联系客服页面 image src="https://p3.douyinpic.com/aweme/100x100/aweme-avatar/tos-cn-avt-0015_20775b0106374a94013d7b6f3896d94a.jpeg?from=4010531038" mode=""></image>
</view> </view>
</template> </template>
<script> <script>
// export default { export default {
// data() { data() {
// return { return {
// hotCreatorList: [], list:[{
// isTarget: true, url: '/pages-userInfo/about/about',
// showChoiceness:false title: '关于节点',
// } img: ''
// }, },{
// // url: '/pages-userInfo/contact/contact',
// onPullDownRefresh() { title: '联系我们',
// this.showChoiceness = false img: ''
// uni.stopPullDownRefresh() },{
// }, url: '/pages-userInfo/extends/extends',
// created() { title: '邀请他人',
// const userInfo = uni.getStorageSync('userInfo') img: ''
// if (!userInfo) { },{
// console.log('havent userInfo') url: '/pages-userInfo/inviteLog/inviteLog',
// this.getUserInfo() title: '邀请记录',
// } else { img: ''
// console.log('have userInfo') },{
// } url: '/pages-userInfo/notice/notice',
// }, title: '通知公告',
// onPageScroll(e) { img: ''
// // scrollTopeasy-loadimage },{
url: '/pages-userInfo/withdraw/withdraw',
// if (e.scrollTop > 160) { title: '提现记录',
// this.showChoiceness = true img: ''
// // uni.redirectTo({ }],
// // url: '../index/choiceness' pageUrl: '',
// // }) userInfo: {}
// } }
// }, },
// methods: { created() {
// // this.userInfo = uni.getStorageSync('userInfo')
// search(res) { console.log('this.userInfo',this.userInfo)
// if (res.value) { },
// console.log('search', res.value) methods: {
// this.goCreatorDetail(res.value) change(e) {
// } else { let {
// uni.showToast({ index
// title: '', } = e.detail
// icon: 'none' this.pageUrl = this.list[index].url
// }) console.log('this.pageUrl',this.pageUrl)
// } /** 跳转指定页面*/
uni.navigateTo({
// }, url: this.pageUrl
// // });
// getUserInfo() { },
// wx.login({ },
// force: true, }
// success: res => {
// wx.getUserInfo({
// withCredentials: true,
// success: userInfo => {
// const params = {
// code: res.code,
// encryptedData: userInfo.encryptedData,
// iv: userInfo.iv
// }
// //
// console.log('params',params);
// loginWx(params).then(res => {
// if (res.data.code === 200) {
// uni.setStorage({
// key: 'userInfo',
// data: res.data.data.userInfo,
// })
// } else {
// uni.showToast({
// title: res.data.msg,
// icon: 'none'
// })
// }
// }).catch(res => {})
// console.log(`getUserInfo `, userInfo);
// },
// fail(userInfo) {
// console.log(`getUserInfo `);
// },
// });
// },
// fail(res) {
// console.log(`login `);
// },
// });
// },
// //
// handleScroll() {
// let scrollTop = window.pageYOffset || document.documentElement.scrollTop || document.body.scrollTop
// console.log(scrollTop)
// },
// },
// }
</script> </script>
<style lang="less"> <style lang="less">

19
pages-userInfo/inviteLog/inviteLog.vue

@ -3,6 +3,7 @@
<uni-list border-full v-for="(item,index) in inviteLogList" :key="index"> <uni-list border-full v-for="(item,index) in inviteLogList" :key="index">
<uni-list-item :title="item.invitedScanCode" :note="item.createTime" :thumb="item.img" thumb-size="lg" /> <uni-list-item :title="item.invitedScanCode" :note="item.createTime" :thumb="item.img" thumb-size="lg" />
</uni-list> </uni-list>
<view class="ivOver" v-if="flag">-----已经到底啦-----</view>
</view> </view>
</template> </template>
@ -16,7 +17,8 @@
inviteLogList: [], inviteLogList: [],
pageSize: 10, pageSize: 10,
pageNum: 1, pageNum: 1,
userInfo: {} userInfo: {},
flag: false
} }
}, },
created() { created() {
@ -33,9 +35,12 @@
}, },
// //
onReachBottom() { onReachBottom() {
if (this.inviteLogList.length > 9) { if (this.inviteLogList.length > this.pageSize*this.pageNum-1) {
this.flag = false;
this.pageNum += 1 this.pageNum += 1
this.getInviteLog(); this.getInviteLog();
}else{
this.flag = true;
} }
}, },
methods: { methods: {
@ -62,7 +67,15 @@
} }
</script> </script>
<style lang="less"> <style lang="scss">
.ivOver{
width: 100%;
height:50px;
line-height: 50px;
text-align: center;
background: #fff;
font-size: 20rpx;
}
.container { .container {
.top { .top {
width: 100vw; width: 100vw;

17
pages-userInfo/notice/notice.vue

@ -4,6 +4,7 @@
<uni-list-item showArrow clickable :title="item.title" :note="item.createTime" :thumb="item.img" <uni-list-item showArrow clickable :title="item.title" :note="item.createTime" :thumb="item.img"
thumb-size="lg" @click="targetToDetail(item.id)" /> thumb-size="lg" @click="targetToDetail(item.id)" />
</uni-list> </uni-list>
<view class="ivOver" v-if="flag">-----已经到底啦-----</view>
</view> </view>
</template> </template>
@ -16,7 +17,8 @@
return { return {
noticeList: [], noticeList: [],
pageSize: 10, pageSize: 10,
pageNum: 1 pageNum: 1,
flag: false
} }
}, },
created() { created() {
@ -31,9 +33,12 @@
}, },
// //
onReachBottom() { onReachBottom() {
if (this.noticeList.length > 9) { if (this.noticeList.length > this.pageSize*this.pageNum-1) {
this.flag = false;
this.pageNum += 1 this.pageNum += 1
this.getNoticeList(); this.getNoticeList();
}else{
this.flag = true;
} }
}, },
methods: { methods: {
@ -69,4 +74,12 @@
</script> </script>
<style lang="scss"> <style lang="scss">
.ivOver{
width: 100%;
height:50px;
line-height: 50px;
text-align: center;
background: #fff;
font-size: 20rpx;
}
</style> </style>

19
pages-userInfo/withdraw/withdraw.vue

@ -5,6 +5,7 @@
:note="item.createTime+'||'+item.channel+'||'+item.status" :rightText="'¥'+item.amt" :note="item.createTime+'||'+item.channel+'||'+item.status" :rightText="'¥'+item.amt"
@click="targetToDetail(item.orderId)" /> @click="targetToDetail(item.orderId)" />
</uni-list> </uni-list>
<view class="ivOver" v-if="flag">-----已经到底啦-----</view>
</view> </view>
</template> </template>
@ -18,7 +19,8 @@
withdrawList: [], withdrawList: [],
pageSize: 10, pageSize: 10,
pageNum: 1, pageNum: 1,
userInfo: {} userInfo: {},
flag: false
} }
}, },
created() { created() {
@ -35,9 +37,12 @@
}, },
// //
onReachBottom() { onReachBottom() {
if (this.withdrawList.length > 9) { if (this.withdrawList.length > this.pageSize*this.pageNum-1) {
this.flag = false;
this.pageNum += 1 this.pageNum += 1
this.getWithdrawList(); this.getWithdrawList();
}else{
this.flag = true;
} }
}, },
methods: { methods: {
@ -71,7 +76,15 @@
} }
</script> </script>
<style lang="less"> <style lang="scss">
.ivOver{
width: 100%;
height:50px;
line-height: 50px;
text-align: center;
background: #fff;
font-size: 20rpx;
}
.container { .container {
.top { .top {
width: 100vw; width: 100vw;

85
pages/profit/profitEndDetails.vue

@ -6,18 +6,20 @@
</view> </view>
<view class="content"> <view class="content">
<view v-if="typeId === 0"> <view v-if="typeId === 0">
<uni-list border-full v-for="(item,index) in endProfitList" :key="index"> <uni-list border-full v-for="(item,index) in endProfitAdList" :key="index">
<uni-list-item showArrow clickable :title="item.walletTime+'@'+item.scanCode" <uni-list-item showArrow clickable :title="item.walletTime+'@'+item.scanCode"
:note="item.appType+'&'+item.platform+'&'+item.type" :thumb="item.url" thumb-size="lg" :note="item.appType+'&'+item.platform+'&'+item.type" :thumb="item.url" thumb-size="lg"
:rightText="'¥'+item.profit" @click="targetToOrder(item.id)" /> :rightText="'¥'+item.profit" @click="targetToOrder(item.id)" />
</uni-list> </uni-list>
<view class="ivOver" v-if="flagAd">-----已经到底啦-----</view>
</view> </view>
<view v-if="typeId === 1"> <view v-if="typeId === 1">
<uni-list border-full v-for="(item,index) in endProfitList" :key="index"> <uni-list border-full v-for="(item,index) in endProfitInviteList" :key="index">
<uni-list-item showArrow clickable :title="item.walletTime+'@'+item.scanCode" <uni-list-item showArrow clickable :title="item.walletTime+'@'+item.scanCode"
:note="item.appType+'&'+item.platform+'&'+item.type" :thumb="item.url" thumb-size="lg" :note="item.appType+'&'+item.platform+'&'+item.type" :thumb="item.url" thumb-size="lg"
:rightText="'¥'+item.profit" @click="targetToOrder(item.id)" /> :rightText="'¥'+item.profit" @click="targetToOrder(item.id)" />
</uni-list> </uni-list>
<view class="ivOver" v-if="flagInvite">-----已经到底啦-----</view>
</view> </view>
</view> </view>
</view> </view>
@ -34,8 +36,13 @@
typeId: 0, typeId: 0,
activeColor: '#007aff', activeColor: '#007aff',
styleType: 'text', styleType: 'text',
endProfitList: [], endProfitAdList: [],
userInfo: {} endProfitInviteList: [],
userInfo: {},
pageSize: 10,
pageNum: 1,
flagAd: false,
flagInvite: false
} }
}, },
created() { created() {
@ -49,16 +56,57 @@
this.queryFrontEndProfitAmt() this.queryFrontEndProfitAmt()
} }
}, },
//
onPullDownRefresh() {
if(this.typeId === 0){
this.pageNum = 1
this.endProfitAdList = []
this.queryFrontEndProfitAmt()
uni.stopPullDownRefresh()
}else{
this.pageNum = 1
this.endProfitInviteList = []
this.queryFrontEndProfitAmt()
uni.stopPullDownRefresh()
}
},
//
onReachBottom() {
if(this.typeId === 0){
if (this.endProfitAdList.length > this.pageNum*this.pageSize-1 ) {
this.flagAd = false;
this.pageNum += 1
this.queryFrontEndProfitAmt();
}else{
this.flagAd = true;
}
}else{
if (this.endProfitInviteList.length > this.pageNum*this.pageSize-1 ) {
this.flagInvite = false;
this.pageNum += 1
this.queryFrontEndProfitAmt();
}else{
this.flagInvite = true;
}
}
},
methods: { methods: {
// //
async queryFrontEndProfitAmt() { async queryFrontEndProfitAmt() {
const res = await queryFrontEndProfitAmt({ const res = await queryFrontEndProfitAmt({
creatorId: this.userInfo.id, creatorId: this.userInfo.id,
type: this.typeId type: this.typeId,
pageSize: this.pageSize,
pageNum: this.pageNum
}) })
if (res.data.code === 200) { if (res.data.code === 200) {
this.endProfitList = res.data.data if(this.typeId === 0){
this.endProfitAdList.push(...res.data.rows)
}else{
this.endProfitInviteList.push(...res.data.rows)
}
} else { } else {
uni.showModal({ uni.showModal({
content: '转入钱包列表数据加载失败!', content: '转入钱包列表数据加载失败!',
@ -69,6 +117,8 @@
onClickItem(e) { onClickItem(e) {
let that = this let that = this
that.endProfitAdList = []
that.endProfitInviteList = []
if (that.typeId !== e.currentIndex) { if (that.typeId !== e.currentIndex) {
that.typeId = e.currentIndex that.typeId = e.currentIndex
uni.showLoading({ uni.showLoading({
@ -78,12 +128,20 @@
// //
const param = { const param = {
creatorId: that.userInfo.id, creatorId: that.userInfo.id,
type: that.typeId type: that.typeId,
pageSize: that.pageSize,
pageNum: 1
} }
queryFrontEndProfitAmt(param).then(res => { queryFrontEndProfitAmt(param).then(res => {
//console.log('res', res) //console.log('res', res)
if (res.data.code === 200) { if (res.data.code === 200) {
that.endProfitList = res.data.data if(that.typeId === 0){
that.endProfitAdList.push(...res.data.rows)
}else{
that.endProfitInviteList.push(...res.data.rows)
}
console.log('点击操作endProfitAdList',that.endProfitAdList)
console.log('点击操作endProfitInviteList',that.endProfitInviteList)
} else { } else {
uni.showModal({ uni.showModal({
content: '转入钱包列表数据加载失败!', content: '转入钱包列表数据加载失败!',
@ -112,6 +170,13 @@
} }
</script> </script>
<style> <style lang="scss">
.ivOver{
width: 100%;
height:50px;
line-height: 50px;
text-align: center;
background: #fff;
font-size: 20rpx;
}
</style> </style>

85
pages/profit/profitInDetails.vue

@ -6,18 +6,20 @@
</view> </view>
<view class="content"> <view class="content">
<view v-if="typeId === 0"> <view v-if="typeId === 0">
<uni-list border-full v-for="(item,index) in inProfitList" :key="index"> <uni-list border-full v-for="(item,index) in inProfitAdList" :key="index">
<uni-list-item showArrow clickable :title="item.createTime+'@'+item.scanCode" <uni-list-item showArrow clickable :title="item.createTime+'@'+item.scanCode"
:note="item.appType+'&'+item.platform+'&'+item.type" :thumb="item.url" thumb-size="lg" :note="item.appType+'&'+item.platform+'&'+item.type" :thumb="item.url" thumb-size="lg"
:rightText="'¥'+item.profit" @click="targetToOrder(item.id)" /> :rightText="'¥'+item.profit" @click="targetToOrder(item.id)" />
</uni-list> </uni-list>
<view class="ivOver" v-if="flagAd">-----已经到底啦-----</view>
</view> </view>
<view v-if="typeId === 1"> <view v-if="typeId === 1">
<uni-list border-full v-for="(item,index) in inProfitList" :key="index"> <uni-list border-full v-for="(item,index) in inProfitInviteList" :key="index">
<uni-list-item showArrow clickable :title="item.createTime+'@'+item.scanCode" <uni-list-item showArrow clickable :title="item.createTime+'@'+item.scanCode"
:note="item.appType+'&'+item.platform+'&'+item.type" :thumb="item.url" thumb-size="lg" :note="item.appType+'&'+item.platform+'&'+item.type" :thumb="item.url" thumb-size="lg"
:rightText="'¥'+item.profit" @click="targetToOrder(item.id)" /> :rightText="'¥'+item.profit" @click="targetToOrder(item.id)" />
</uni-list> </uni-list>
<view class="ivOver" v-if="flagInvite">-----已经到底啦-----</view>
</view> </view>
</view> </view>
</view> </view>
@ -34,8 +36,13 @@
typeId: 0, typeId: 0,
activeColor: '#007aff', activeColor: '#007aff',
styleType: 'text', styleType: 'text',
inProfitList: [], inProfitAdList: [],
userInfo: {} inProfitInviteList: [],
userInfo: {},
pageSize: 10,
pageNum: 1,
flagAd: false,
flagInvite: false
} }
}, },
created() { created() {
@ -49,16 +56,57 @@
this.queryFrontInProfitAmt() this.queryFrontInProfitAmt()
} }
}, },
//
onPullDownRefresh() {
if(this.typeId === 0){
this.pageNum = 1
this.inProfitAdList = []
this.queryFrontInProfitAmt()
uni.stopPullDownRefresh()
}else{
this.pageNum = 1
this.inProfitInviteList = []
this.queryFrontInProfitAmt()
uni.stopPullDownRefresh()
}
},
//
onReachBottom() {
if(this.typeId === 0){
if (this.inProfitAdList.length > this.pageNum*this.pageSize-1 ) {
this.flagAd = false;
this.pageNum += 1
this.queryFrontInProfitAmt();
}else{
this.flagAd = true;
}
}else{
if (this.inProfitInviteList.length > this.pageNum*this.pageSize-1 ) {
this.flagInvite = false;
this.pageNum += 1
this.queryFrontInProfitAmt();
}else{
this.flagInvite = true;
}
}
},
methods: { methods: {
// //
async queryFrontInProfitAmt() { async queryFrontInProfitAmt() {
const res = await queryFrontInProfitAmt({ const res = await queryFrontInProfitAmt({
creatorId: this.userInfo.id, creatorId: this.userInfo.id,
type: this.typeId type: this.typeId,
pageSize: this.pageSize,
pageNum: this.pageNum
}) })
if (res.data.code === 200) { if (res.data.code === 200) {
this.inProfitList = res.data.data if(this.typeId === 0){
this.inProfitAdList.push(...res.data.rows)
}else{
this.inProfitInviteList.push(...res.data.rows)
}
} else { } else {
uni.showModal({ uni.showModal({
content: '已入账列表数据加载失败!', content: '已入账列表数据加载失败!',
@ -69,6 +117,8 @@
onClickItem(e) { onClickItem(e) {
let that = this let that = this
that.inProfitAdList = []
that.inProfitInviteList = []
if (that.typeId !== e.currentIndex) { if (that.typeId !== e.currentIndex) {
that.typeId = e.currentIndex that.typeId = e.currentIndex
uni.showLoading({ uni.showLoading({
@ -78,11 +128,19 @@
// //
const param = { const param = {
creatorId: that.userInfo.id, creatorId: that.userInfo.id,
type: that.typeId type: that.typeId,
pageSize: that.pageSize,
pageNum: 1
} }
queryFrontInProfitAmt(param).then(res => { queryFrontInProfitAmt(param).then(res => {
if (res.data.code === 200) { if (res.data.code === 200) {
that.inProfitList = res.data.data if(that.typeId === 0){
that.inProfitAdList.push(...res.data.rows)
}else{
that.inProfitInviteList.push(...res.data.rows)
}
console.log('点击操作inProfitAdList',that.inProfitAdList)
console.log('点击操作inProfitInviteList',that.inProfitInviteList)
} else { } else {
uni.showModal({ uni.showModal({
content: '已入账列表数据加载失败!', content: '已入账列表数据加载失败!',
@ -111,6 +169,13 @@
} }
</script> </script>
<style> <style lang="scss">
.ivOver {
width: 100%;
height: 50px;
line-height: 50px;
text-align: center;
background: #fff;
font-size: 20rpx;
}
</style> </style>

64
pages/profit/profitPreDetails.vue

@ -11,7 +11,7 @@
:note="item.appType+'&'+item.platform+'&'+item.type" :thumb="item.url" thumb-size="lg" :note="item.appType+'&'+item.platform+'&'+item.type" :thumb="item.url" thumb-size="lg"
:rightText="item.downloadNum+'次'" /> :rightText="item.downloadNum+'次'" />
</uni-list> </uni-list>
<view class="ivOver" v-if="flag">-----已经到底啦-----</view> <view class="ivOver" v-if="flagAd">-----已经到底啦-----</view>
</view> </view>
<view v-if="typeId === 1"> <view v-if="typeId === 1">
<uni-list border-full v-for="(item,index) in preprofitInviteList" :key="index"> <uni-list border-full v-for="(item,index) in preprofitInviteList" :key="index">
@ -19,7 +19,7 @@
:note="item.appType+'&'+item.platform+'&'+item.type" :thumb="item.url" thumb-size="lg" :note="item.appType+'&'+item.platform+'&'+item.type" :thumb="item.url" thumb-size="lg"
:rightText="item.downloadNum+'次'" /> :rightText="item.downloadNum+'次'" />
</uni-list> </uni-list>
<view class="ivOver" v-if="flag">-----已经到底啦-----</view> <view class="ivOver" v-if="flagInvite">-----已经到底啦-----</view>
</view> </view>
</view> </view>
</view> </view>
@ -41,7 +41,8 @@
userInfo: {}, userInfo: {},
pageSize: 10, pageSize: 10,
pageNum: 1, pageNum: 1,
flag: false flagAd: false,
flagInvite: false
} }
}, },
created() { created() {
@ -57,25 +58,44 @@
}, },
// //
onPullDownRefresh() { onPullDownRefresh() {
this.pageNum = 1 if(this.typeId === 0){
this.preProfitList = [] this.pageNum = 1
this.queryFrontPreProfit() this.preProfitAdList = []
uni.stopPullDownRefresh() this.queryFrontPreProfit()
uni.stopPullDownRefresh()
}else{
this.pageNum = 1
this.preprofitInviteList = []
this.queryFrontPreProfit()
uni.stopPullDownRefresh()
}
}, },
// //
onReachBottom() { onReachBottom() {
console.log('this.preProfitList.length',this.preProfitList.length) if(this.typeId === 0){
if (this.preProfitList.length > this.pageNum*this.pageSize-1 ) { if (this.preProfitAdList.length > this.pageNum*this.pageSize-1 ) {
this.flag = false; this.flagAd = false;
this.pageNum += 1 this.pageNum += 1
this.queryFrontPreProfit(); this.queryFrontPreProfit();
}else{
this.flagAd = true;
}
}else{ }else{
this.flag = true; if (this.preprofitInviteList.length > this.pageNum*this.pageSize-1 ) {
this.flagInvite = false;
this.pageNum += 1
this.queryFrontPreProfit();
}else{
this.flagInvite = true;
}
} }
}, },
methods: { methods: {
onClickItem(e) { onClickItem(e) {
let that = this let that = this
that.preProfitAdList = []
that.preprofitInviteList = []
if (that.typeId !== e.currentIndex) { if (that.typeId !== e.currentIndex) {
that.typeId = e.currentIndex that.typeId = e.currentIndex
uni.showLoading({ uni.showLoading({
@ -91,15 +111,13 @@
} }
queryFrontPreProfit(param).then(res => { queryFrontPreProfit(param).then(res => {
if (res.data.code === 200) { if (res.data.code === 200) {
if(this.typeId = 0){ if(that.typeId === 0){
this.preProfitAdList.push(...res.data.rows) that.preProfitAdList.push(...res.data.rows)
}else{ }else{
this.preprofitInviteList.push(...res.data.rows) that.preprofitInviteList.push(...res.data.rows)
} }
console.log('点击操作preProfitAdList',this.preProfitAdList) console.log('点击操作preProfitAdList',that.preProfitAdList)
console.log('点击操作preprofitInviteList',this.preprofitInviteList) console.log('点击操作preprofitInviteList',that.preprofitInviteList)
that.preProfitList = res.data.rows
this.flag = false;
} else { } else {
uni.showModal({ uni.showModal({
content: '即将到账列表数据加载失败!', content: '即将到账列表数据加载失败!',
@ -124,18 +142,12 @@
pageSize: this.pageSize, pageSize: this.pageSize,
pageNum: this.pageNum pageNum: this.pageNum
}) })
console.log('this.typeId1',this.typeId)
if (res.data.code === 200) { if (res.data.code === 200) {
console.log('this.typeId2',this.typeId)
if(this.typeId === 0){ if(this.typeId === 0){
console.log('this.typeId3',this.typeId)
this.preProfitAdList.push(...res.data.rows) this.preProfitAdList.push(...res.data.rows)
}else{ }else{
console.log('this.typeId4',this.typeId)
this.preprofitInviteList.push(...res.data.rows) this.preprofitInviteList.push(...res.data.rows)
} }
console.log('this.preProfitAdList',this.preProfitAdList)
console.log('this.preprofitInviteList',this.preprofitInviteList)
} else { } else {
uni.showModal({ uni.showModal({
content: '即将到账列表数据加载失败!', content: '即将到账列表数据加载失败!',

Loading…
Cancel
Save