Commit b65022f2 authored by Mac's avatar Mac

1

parent 9c59a22b
...@@ -157,7 +157,13 @@ ...@@ -157,7 +157,13 @@
}, },
{ {
"path": "buyInterest/index" "path": "buyInterest/index"
} },
{
"path":"salesvolume",
"style": {
"navigationStyle": "custom"
}
}
] ]
}, },
{ {
......
...@@ -297,7 +297,16 @@ ...@@ -297,7 +297,16 @@
<Text style="font-size: 12px;margin-top: 5px;height:19px;font-family:'cuIcon'">{{headData.createDateStr}}</Text> <Text style="font-size: 12px;margin-top: 5px;height:19px;font-family:'cuIcon'">{{headData.createDateStr}}</Text>
</view> </view>
</view> </view>
<image mode="widthFix" @click="godiagram" src="../../static/images/useRrelationship.png" style="width:75px;height:24px;"></image> <view style="display: flex;flex-direction: column;align-items: flex-end;">
<view>
<image mode="widthFix" @click="godiagram" src="../../static/images/useRrelationship.png" style="width:75px;height:24px;"></image>
</view>
<view>
<image mode="widthFix" @click="gosales()" src="../../static/images/xiaoshoue.png" style="width:70px;height:24px;margin-top: 5px;"></image>
</view>
</view>
</view> </view>
<view class="sharebox_topc"> <view class="sharebox_topc">
<view class="center_item" style="font-size: 12px;color: #FFFFFF;justify-content: space-between;"> <view class="center_item" style="font-size: 12px;color: #FFFFFF;justify-content: space-between;">
...@@ -791,8 +800,15 @@ ...@@ -791,8 +800,15 @@
} }
} }
); );
} },
gosales(){
uni.navigateTo({
url: '/pages/share/salesvolume?UserId='+this.headMsg.UserId
});
},
}, },
created() { created() {
this.contentHeight = this.$utils.calcContentHeight(-40) + 'px'; this.contentHeight = this.$utils.calcContentHeight(-40) + 'px';
this.mainColor = this.$uiConfig.mainColor; this.mainColor = this.$uiConfig.mainColor;
......
...@@ -223,7 +223,7 @@ ...@@ -223,7 +223,7 @@
this.startTimeString = this.timeArr[0] this.startTimeString = this.timeArr[0]
} }
console.log('timeArr',this.timeArr)
// }else{ // }else{
// uni.showToast({ // uni.showToast({
// title:"选择日期不能小于当天!", // title:"选择日期不能小于当天!",
...@@ -258,7 +258,7 @@ ...@@ -258,7 +258,7 @@
dayArray: this.dealDateArray(year, month) //日数组 dayArray: this.dealDateArray(year, month) //日数组
}) })
} }
console.log('列表', this.dateList)
}, },
// 获取传参日期后处理出当天时间戳(重要) // 获取传参日期后处理出当天时间戳(重要)
dealStarAndEndDay() { dealStarAndEndDay() {
...@@ -380,7 +380,8 @@ ...@@ -380,7 +380,8 @@
bottom:-100%; bottom:-100%;
width: 100%; width: 100%;
box-sizing: border-box; box-sizing: border-box;
padding: 0 62rpx; padding: 0 62rpx;
z-index: 99999;
// 头部操作区域 // 头部操作区域
.navTop { .navTop {
position: relative; position: relative;
...@@ -392,7 +393,7 @@ ...@@ -392,7 +393,7 @@
// 取消按钮 // 取消按钮
.cancel { .cancel {
font-size: 28rpx; font-size: 28rpx;
z-index: 10; z-index: 999999;
} }
// 标题 // 标题
...@@ -542,7 +543,8 @@ ...@@ -542,7 +543,8 @@
align-items: center; align-items: center;
justify-content: space-between; justify-content: space-between;
background-color: #fff; background-color: #fff;
z-index: 1;
z-index: 199999;
border-top: 1rpx #ededed solid; border-top: 1rpx #ededed solid;
view { view {
......
...@@ -90,7 +90,7 @@ ...@@ -90,7 +90,7 @@
<view style="width: 2px;height: 25px;background: #FFFFFF;justify-content: space-between;"></view> <view style="width: 2px;height: 25px;background: #FFFFFF;justify-content: space-between;"></view>
<view class="center_item" style="font-size: 12px;color: #FFFFFF;" @click="gosales()"> <view class="center_item" style="font-size: 12px;color: #FFFFFF;" @click="gosales()">
<Text>销售额</Text> <Text>销售额</Text>
<Text>0</Text> <Text>{{sharedata.UserInfo.MySellMoney!=null ?sharedata.UserInfo.MySellMoney:0}}</Text>
</view> </view>
</view> </view>
<!-- 会员购买 --> <!-- 会员购买 -->
...@@ -178,7 +178,6 @@ ...@@ -178,7 +178,6 @@
<u-icon name="arrow" size="24" color="#A5A3AB"></u-icon> <u-icon name="arrow" size="24" color="#A5A3AB"></u-icon>
</view> </view>
</view> </view>
</view> </view>
<view class="sharebox_menus" v-if="UserPageType.UserPageType!=2"> <view class="sharebox_menus" v-if="UserPageType.UserPageType!=2">
<view class="menus_item" @click="goUrl('/pages/share-qrcode/share-qrcode',1)"> <view class="menus_item" @click="goUrl('/pages/share-qrcode/share-qrcode',1)">
......
...@@ -83,18 +83,18 @@ ...@@ -83,18 +83,18 @@
</view> </view>
<view class="top-b"> <view class="top-b">
<view class="top-b-item"> <view class="top-b-item">
<text class="distext">我的总销售额</text> <text class="distext">{{showText==0?'我的总销售额':'TA的总销售额'}} </text>
<view class="dised" style="font-size: 17px;">{{data.MySellMoney?data.MySellMoney.toFixed(2):0}} <text style="font-size: 10px;margin-bottom: 6rpx;">(元)</text> </view> <view class="dised" style="font-size: 17px;">{{data.MySellMoney?data.MySellMoney.toFixed(2):0}} <text style="font-size: 10px;margin-bottom: 6rpx;">(元)</text> </view>
</view> </view>
<view style="width: 1px;height: 30px;background: #FFF;"></view> <view style="width: 1px;height: 30px;background: #FFF;"></view>
<view class="top-b-item"> <view class="top-b-item">
<text class="distext">线下总销售额</text> <text class="distext">下线总销售额</text>
<view class="dised" style="font-size: 17px;">{{data.ReSellMoney?data.ReSellMoney.toFixed(2):0}} <text style="font-size: 10px;margin-bottom: 6rpx;">(元)</text> </view> <view class="dised" style="font-size: 17px;">{{data.ReSellMoney?data.ReSellMoney.toFixed(2):0}} <text style="font-size: 10px;margin-bottom: 6rpx;">(元)</text> </view>
</view> </view>
</view> </view>
</view> </view>
<view style="width: 100%;padding:0 15px;display: flex;align-items: center;justify-content: space-between;height: 50px;"> <view style="width: 100%;padding:0 15px;display: flex;align-items: center;justify-content: space-between;height: 50px;">
<text style="font-size: 17px;color: #000000;font-weight: bold;">我的销售额</text> <text style="font-size: 17px;color: #000000;font-weight: bold;">{{showText==0?'我的销售额':'销售额'}}</text>
</view> </view>
<view style="width: 100%;display: flex;align-items: center;justify-content: center;"> <view style="width: 100%;display: flex;align-items: center;justify-content: center;">
...@@ -104,28 +104,32 @@ ...@@ -104,28 +104,32 @@
</view> </view>
</view> </view>
<canvas canvas-id="canvasColumn" id="canvasColumn" class="charts" disable-scroll=true <canvas canvas-id="canvasColumn" id="canvasColumn" class="charts" disable-scroll=true
@touchstart="touchColumn" @touchmove="moveColumn" @touchend="touchEndColumn"> @touchstart="touchColumn" @touchmove="moveColumn" @touchend="touchEndColumn">
<cover-view>
<calendar ref="calendar" v-if="show"
@cancel="show=false"
:startDate="msg.StartTime"
:height="height"
:endDate="msg.EndTime"
@selectDate="selectDate"
:limit="limit" />
</cover-view>
</canvas> </canvas>
<view class="zongjie"> <view class="zongjie">
<view class="zongjie-item"> <view class="zongjie-item">
<text>我的销售额</text> <text>{{showText==0?'我的销售额':'销售额'}}</text>
<text style="font-size: 22px;color: #000000;">{{timeMySale.toFixed(2)}}</text> <text :style="{'font-size':timeMySale>10000 ||timeReSale>10000 ?'12px': '22px','color': '#000000'}">{{timeMySale.toFixed(2)}}</text>
</view> </view>
<view style="width: 1px;height: 30px;background: #D2D2D2;"></view> <view style="width: 1px;height: 30px;background: #D2D2D2;"></view>
<view class="zongjie-item"> <view class="zongjie-item">
<text>线下销售额</text> <text>下线销售额</text>
<text style="font-size: 22px;color: #000000;">{{timeReSale.toFixed(2)}}</text> <text :style="{'font-size':timeMySale>10000 ||timeReSale>10000?'12px': '22px','color': '#000000'}">{{timeReSale.toFixed(2)}}</text>
</view> </view>
</view> </view>
</view> </view>
<calendar ref="calendar" v-if="show"
@cancel="show=false"
:startDate="msg.StartTime"
:height="height"
:endDate="msg.EndTime"
@selectDate="selectDate"
:limit="limit" />
</view> </view>
</scroll-view> </scroll-view>
...@@ -151,6 +155,7 @@ ...@@ -151,6 +155,7 @@
secondary: '', secondary: '',
headStyle: {}, headStyle: {},
scrollTop: 0, scrollTop: 0,
showText:0,//显示我还是他 0 是我 1 是他
params: { params: {
year: true, year: true,
month: true, month: true,
...@@ -195,13 +200,18 @@ ...@@ -195,13 +200,18 @@
onLoad(options) { onLoad(options) {
_self = this; _self = this;
if (options && options.UserId) { if (options && options.UserId) {
this.msg.UserId = options.UserId; this.msg.UserId = options.UserId;
let UserId = uni.getStorageSync('mall_UserInfo')?uni.getStorageSync('mall_UserInfo').UserId : 0;
if( UserId != this.msg.UserId ){
this.showText = 1
}
this.getTime() this.getTime()
} }
}, },
methods: { methods: {
// 获取传参 // 获取传参
selectDate(data) { selectDate(data) {
console.log(data)
if(data.dayNum>30){ if(data.dayNum>30){
uni.showToast({ uni.showToast({
title: '时间不能超过30天', title: '时间不能超过30天',
...@@ -232,21 +242,22 @@ ...@@ -232,21 +242,22 @@
res => { res => {
if (res.resultCode == 1) { if (res.resultCode == 1) {
this.data = res.data this.data = res.data
this.data.DayList = [{Day: "2020-04-10",MySale: 80,ReSale: 70}, // this.data.DayList = [{Day: "2020-04-10",MySale: 80,ReSale: 70},
{Day: "2020-04-11",MySale: 100,ReSale: 40}, // {Day: "2020-04-11",MySale: 100,ReSale: 40},
{Day: "2020-04-12",MySale: 20,ReSale: 30}, // {Day: "2020-04-12",MySale: 20,ReSale: 30},
{Day: "2020-04-13",MySale: 30,ReSale: 120}, // {Day: "2020-04-13",MySale: 30,ReSale: 120},
{Day: "2020-04-14",MySale: 58,ReSale: 67}, // {Day: "2020-04-14",MySale: 58,ReSale: 67},
{Day: "2020-04-15",MySale: 90,ReSale: 100}, // {Day: "2020-04-15",MySale: 90,ReSale: 100},
{Day: "2020-04-16",MySale: 23,ReSale: 400}, // {Day: "2020-04-16",MySale: 23,ReSale: 400},
] // ]
let Column = { let Column = {
categories: [], categories: [],
series: [] series: []
}; };
let myName = this.showText==0?'自己销售额':'销售额'
let MySale={ let MySale={
name:'自己销售额', name:myName,
data:[], data:[],
color: "#3FE5ED", color: "#3FE5ED",
index: 0, index: 0,
...@@ -257,7 +268,7 @@ ...@@ -257,7 +268,7 @@
}; };
let ReSale={ let ReSale={
name:'线下销售额', name:'下线销售额',
data:[], data:[],
color: "#D86CFB", color: "#D86CFB",
index: 0, index: 0,
...@@ -277,7 +288,6 @@ ...@@ -277,7 +288,6 @@
ReSale.data.push(x.ReSale) ReSale.data.push(x.ReSale)
}) })
Column.series = [MySale,ReSale] Column.series = [MySale,ReSale]
console.log(Column)
_self.showColumn("canvasColumn",Column); _self.showColumn("canvasColumn",Column);
} }
} }
...@@ -458,5 +468,10 @@ ...@@ -458,5 +468,10 @@
width: 1px; width: 1px;
margin-left: 10px; margin-left: 10px;
line-height: 34px; line-height: 34px;
} }
cover-view,
cover-image {
display: inline-block;
}
</style> </style>
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