Commit 7fc0eee6 by sunchao

个人信息接口调整

parent 9997376d
...@@ -153,7 +153,7 @@ ...@@ -153,7 +153,7 @@
"path" : "pages/myPoints/myPoints", "path" : "pages/myPoints/myPoints",
"style" : "style" :
{ {
"navigationBarTitleText": "", "navigationBarTitleText": "我的积分",
"enablePullDownRefresh": false "enablePullDownRefresh": false
} }
} }
...@@ -189,7 +189,13 @@ ...@@ -189,7 +189,13 @@
"navigationBarTitleText": "我的售后", "navigationBarTitleText": "我的售后",
"enablePullDownRefresh": false "enablePullDownRefresh": false
} }
},{
"path" : "pages/myPoints/pointsDetail",
"style" :
{
"navigationBarTitleText": "积分明细",
"enablePullDownRefresh": false
}
} }
], ],
// "tabBar": { // "tabBar": {
......
...@@ -122,12 +122,12 @@ ...@@ -122,12 +122,12 @@
}, },
queryAreaCenterInfo(){ queryAreaCenterInfo(){
api.queryAreaCenterInfo({userId:1}).then((res)=>{ api.queryAreaCenterInfo({userId:1}).then((res)=>{
if(res['commonResult']['success']){ if(res['success']){
this.cffpUserInfo = res; this.cffpUserInfo = res['data'];
// this.cffpUserInfo.logo = res['logo']; // this.cffpUserInfo.logo = res['logo'];
}else{ }else{
uni.showToast({ uni.showToast({
title: res['commonResult']['message'], title: res['message'],
duration: 2000, duration: 2000,
icon: 'none' icon: 'none'
}) })
......
...@@ -3,7 +3,7 @@ ...@@ -3,7 +3,7 @@
<view class="top"> <view class="top">
<view class="exchange_wrapper"> <view class="exchange_wrapper">
<view>可兑换积分 <text style="color: #FF7704;">{{yesExchangeFortune}}积分</text></view> <view>可兑换积分 <text style="color: #FF7704;">{{yesExchangeFortune}}积分</text></view>
<view style="color:#C85E04;text-decoration: underline;">可兑换提现5555.55</view> <view style="color:#C85E04;text-decoration: underline;">可兑换提现{{yesExchangeFortune}}</view>
</view> </view>
<view class="bg"> <view class="bg">
<image src="/static/mypoint_pic.png" mode="widthFix"></image> <image src="/static/mypoint_pic.png" mode="widthFix"></image>
...@@ -29,16 +29,16 @@ ...@@ -29,16 +29,16 @@
</view> </view>
<view class="statistics_wrapper"> <view class="statistics_wrapper">
<view class=""> <view class="">
<text style="color: #0A2F99;">11111</text> <text style="color: #0A2F99;">{{sumCommissionAmount}}</text>
<text>累计积分</text> <text>累计积分</text>
</view> </view>
<view class=""> <view class="">
<text style="color: #F15A1F;">333</text> <text style="color: #F15A1F;">{{nowSumCommissionAmount}}</text>
<text>今日获得积分</text> <text>{{getName(timeFlag)}}获得积分</text>
</view> </view>
<view class=""> <view class="">
<text style="color: #0A2F99;">-222</text> <text style="color: #0A2F99;">{{prePercent}}%</text>
<text>{{prePercent}}</text> <text>{{getInfo(timeFlag)}}得分</text>
</view> </view>
</view> </view>
<view class="point_content"> <view class="point_content">
...@@ -51,7 +51,7 @@ ...@@ -51,7 +51,7 @@
<li>获得积分</li> <li>获得积分</li>
<li>操作</li> <li>操作</li>
</ul> </ul>
<ul class="point_content_list" v-for="pointItem in cffpFortuneDeductionList"> <ul class="point_content_list" v-for="pointItem in cffpFortuneDeductionList" @click="toPointDetail(pointItem)">
<li>{{pointItem.productTypeName}}</li> <li>{{pointItem.productTypeName}}</li>
<li>{{pointItem.commissionTypeName}}</li> <li>{{pointItem.commissionTypeName}}</li>
<li class="get_point">{{pointItem.commissionAmount}}</li> <li class="get_point">{{pointItem.commissionAmount}}</li>
...@@ -91,11 +91,18 @@ ...@@ -91,11 +91,18 @@
this.fortuneDate = e.detail.value; this.fortuneDate = e.detail.value;
}, },
findByUserIdForFortuneStatistic(){ findByUserIdForFortuneStatistic(){
// const param = {
// isDtl:2,
// userId:uni.getStorageSync('cffp_userId'),
// fortuneDate:this.fortuneDate,
// timeFlag:this.timeFlag
// }
const param = { const param = {
isDtl:2, "isDtl": 2,
userId:uni.getStorageSync('cffp_userId'), "userId": 1,
fortuneDate:this.fortuneDate, "fortuneDate": "2022-11-01",
timeFlag:this.timeFlag "timeFlag": "D"
} }
api.findByUserIdForFortuneStatistic(param).then((res)=>{ api.findByUserIdForFortuneStatistic(param).then((res)=>{
console.log(res) console.log(res)
...@@ -104,9 +111,36 @@ ...@@ -104,9 +111,36 @@
this.nowSumCommissionAmount = res['data']['nowSumCommissionAmount'] //当前(日月年)积分 this.nowSumCommissionAmount = res['data']['nowSumCommissionAmount'] //当前(日月年)积分
this.prePercent = res['data']['prePercent'] //比前日、上月,上年多或少的百分比数据 this.prePercent = res['data']['prePercent'] //比前日、上月,上年多或少的百分比数据
this.yesExchangeFortune = res['data']['yesExchangeFortune'] //可兑换金额 this.yesExchangeFortune = res['data']['yesExchangeFortune'] //可兑换金额
this.cffpFortuneDeductionList = res['data']['cffpFortuneDeductionList']; this.cffpFortuneDeductionList = res['data']['cffpFortuneDeductionList']
} }
}) })
},
getInfo(str){
if(str == 'D'){
return '上次';
}
if(str == 'M'){
return '上月';
}
if(str == 'Y'){
return '去年';
}
},
getName(str){
if(str == 'D'){
return '当日';
}
if(str == 'M'){
return '当月';
}
if(str == 'Y'){
return '当年';
}
},
toPointDetail(item){
uni.navigateTo({
url:`../myPoints/pointDetail`
})
} }
} }
} }
...@@ -195,9 +229,12 @@ ...@@ -195,9 +229,12 @@
align-items: center; align-items: center;
height: 70rpx; height: 70rpx;
li{ li{
width: 25%; width: 20%;
text-align: center; text-align: center;
} }
li:nth-child(2){
width: 30%;
}
.get_point{ .get_point{
color: #FF0000; color: #FF0000;
} }
......
<template>
<view class="container">
</view>
</template>
<script>
export default{
data(){
return {
}
},
components:{},
onLoad(){
},
methods:{
getDetail(){
const param = {
"isDtl": 1,
"userId": 1,
"fortuneDate": "2022-12",
"timeFlag": "M",
"commissionType":"A01",
"productType": 1
}
}
}
}
</script>
<style>
</style>
\ No newline at end of file
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment