Commit e1796328 by 杨明

产值

1 parent 8be8e62a
...@@ -4,20 +4,20 @@ Component({ ...@@ -4,20 +4,20 @@ Component({
type: Object, type: Object,
value: {}, value: {},
observer(v) { observer(v) {
if(!v)return if (!v) return
let s = v.statics let s = v
if (s) { if (s) {
v.numList = [ v.numList = [
{title: '浏览量', num: s.browseCount}, { title: '浏览量(次)', num: s.browsCount },
{title: '访客量', num: s.fansCount}, { title: '访客量(人)', num: s.visitCount },
{title: '订单量', num: s.orderCount} { title: '订单量(单)', num: s.orderCount }
] ]
v.sortList = [ v.sortList = [
{title: '访客率', sort: s.fansRate}, { title: '访客率', sort: Number(s.fansRate).toFixed(2) },
{title: '转化率', sort: s.conversionRate} { title: '转化率', sort: Number(s.conversionRate).toFixed(2) }
] ]
} }
this.setData({data: v}) this.setData({ data: v })
} }
} }
}, },
......
...@@ -4,10 +4,10 @@ ...@@ -4,10 +4,10 @@
font-size: 32rpx; font-size: 32rpx;
color: #1B233D; color: #1B233D;
line-height: 48rpx; line-height: 48rpx;
} }
.funnel-box { .funnel-box {
padding: 32rpx 0; padding: 40rpx 0;
position: relative; position: relative;
.funnel-bg { .funnel-bg {
...@@ -15,23 +15,23 @@ ...@@ -15,23 +15,23 @@
top: 40rpx; top: 40rpx;
left: 50%; left: 50%;
transform: translate(-50%); transform: translate(-50%);
// width: 458.18rpx; // width: 406rpx;
// height: 298rpx; // height: 288rpx;
width: 686rpx; width: 686rpx;
height: 408rpx; height: 408rpx;
image { image {
width: 686rpx; width: 686rpx;
height: 408rpx; height: 408rpx;
// width: 458.18rpx; // width: 406rpx;
// height: 298rpx; // height: 288rpx;
} }
} }
.funnel-content { .funnel-content {
display: flex; display: flex;
justify-content: center; justify-content: center;
height: 408rpx; height: 320rpx;
width: 100%; width: 100%;
padding-top: 40rpx; padding-top: 40rpx;
...@@ -41,26 +41,51 @@ ...@@ -41,26 +41,51 @@
} }
.left { .left {
flex: 0 0 406rpx; flex: 0 0 380rpx;
flex-flow: column; flex-flow: column;
justify-content: space-around; justify-content: space-around;
align-items: flex-end; align-items: flex-end;
height: 360rpx;
// align-items: center; // align-items: center;
z-index: 1; z-index: 1;
font-size: 22rpx; font-size: 22rpx;
color: #2D2D33; color: #2D2D33;
box-sizing: border-box; box-sizing: border-box;
padding-right: 20rpx; padding-right: 33rpx;
.labelText:last-child{
.num{
color: #FFFFFF;
}
}
.item-0{
margin-top: 20rpx;
}
.item-1{
margin-top: 20rpx;
}
.item-2{
margin-top: 23rpx;
}
view { view {
box-sizing: border-box;
display: flex; display: flex;
align-items: center; align-items: center;
margin-right: 28rpx; margin-right: 28rpx;
justify-content: space-between;
width: 100%;
padding-left: 40rpx;
text { .num {
font-size: 28rpx; font-size: 28rpx;
font-weight: bold; font-weight: 700;
margin-left: 4rpx; // margin-left: 4rpx;
color: #3666FE;
}
.lable {
font-weight: 400;
font-size: 24rpx;
color: #323436;
} }
} }
} }
...@@ -70,15 +95,28 @@ ...@@ -70,15 +95,28 @@
flex-flow: column; flex-flow: column;
align-items: flex-start; align-items: flex-start;
margin-left: 130rpx; margin-left: 130rpx;
color: #4466F0; // color: #4466F0;
padding-top: 20rpx; color: #3666FE;
padding-top: 85rpx;
font-size: 24rpx; font-size: 24rpx;
position: relative; position: relative;
.sort-box {
font-weight: 400;
font-size: 24rpx;
color: #323436;
.sort {
font-weight: 700;
font-size: 28rpx;
color: #3666FE;
}
}
.sort-box:last-child { .sort-box:last-child {
position: absolute; position: absolute;
left: -46rpx; left: 0rpx;
top: 50%; top: 64%;
} }
.sort { .sort {
...@@ -88,4 +126,4 @@ ...@@ -88,4 +126,4 @@
} }
} }
} }
}
\ No newline at end of file \ No newline at end of file
}
\ No newline at end of file \ No newline at end of file
...@@ -4,13 +4,14 @@ ...@@ -4,13 +4,14 @@
</view> </view>
<view class="funnel-content"> <view class="funnel-content">
<view class="left"> <view class="left">
<view wx:for="{{data.numList}}" wx:key="index">{{item.title}}<text>{{item.num}}</text></view> <view class="labelText item-{{index}}" wx:for="{{data.numList}}" wx:key="index"><text class="label ">{{item.title}}</text><text class="num">{{item.num||0}}</text></view>
</view> </view>
<view class="right"> <view class="right">
<view class="sort-box" wx:for="{{data.sortList}}" wx:key="index"> <view class="sort-box" wx:for="{{data.sortList}}" wx:key="index">
<view>{{item.title}}</view> <view class="label">{{item.title}}</view>
<view class="sort">{{item.sort}}%</view> <view class="sort">{{item.sort}}%</view>
</view> </view>
</view> </view>
</view> </view>
</view> </view>
...@@ -80,6 +80,10 @@ Component({ ...@@ -80,6 +80,10 @@ Component({
scene1TotalSign: (item.curMonthTotalData.scene1Total - item.lastMonthTotalData.scene1Total) > 0, scene1TotalSign: (item.curMonthTotalData.scene1Total - item.lastMonthTotalData.scene1Total) > 0,
scene3Total: Math.abs(item.curMonthTotalData.scene3Total - item.lastMonthTotalData.scene3Total), scene3Total: Math.abs(item.curMonthTotalData.scene3Total - item.lastMonthTotalData.scene3Total),
scene3TotalSign: (item.curMonthTotalData.scene3Total - item.lastMonthTotalData.scene3Total) > 0, scene3TotalSign: (item.curMonthTotalData.scene3Total - item.lastMonthTotalData.scene3Total) > 0,
scene1SolarFilmTotal:Math.abs(item.curMonthTotalData.scene1SolarFilmTotal - item.lastMonthTotalData.scene1SolarFilmTotal),
scene1SolarFilmTotalSign:(item.curMonthTotalData.scene1SolarFilmTotal - item.lastMonthTotalData.scene1SolarFilmTotal)>0,
scene1BoutiqueTotal:Math.abs(item.curMonthTotalData.scene1BoutiqueTotal - item.lastMonthTotalData.scene1BoutiqueTotal),
scene1BoutiqueTotalSign:(item.curMonthTotalData.scene1BoutiqueTotal - item.lastMonthTotalData.scene1BoutiqueTotal)>0
}) })
}) })
this.setData({ this.setData({
......
...@@ -19,16 +19,20 @@ ...@@ -19,16 +19,20 @@
display: flex; display: flex;
align-items: center; align-items: center;
} }
.scene-item { .scene-item {
border-top: 0.3rpx solid #E4E6EE; border-top: 0.3rpx solid #E4E6EE;
padding-top: 4rpx; padding-top: 4rpx;
.list { .list {
border-top: none; border-top: none;
&:nth-child(2) { &:nth-child(2) {
border-top: none; border-top: none;
} }
} }
} }
.scene-item-b { .scene-item-b {
margin-bottom: 26rpx; margin-bottom: 26rpx;
font-size: 24rpx; font-size: 24rpx;
...@@ -39,6 +43,7 @@ ...@@ -39,6 +43,7 @@
text-align: center; text-align: center;
background-image: linear-gradient(270deg, #FFECEC 0%, #DCEEFF 100%); background-image: linear-gradient(270deg, #FFECEC 0%, #DCEEFF 100%);
border-radius: 0 8rpx 8rpx 0; border-radius: 0 8rpx 8rpx 0;
&.long-scene { &.long-scene {
width: 204rpx; width: 204rpx;
} }
...@@ -64,6 +69,19 @@ ...@@ -64,6 +69,19 @@
font-weight: 700; font-weight: 700;
font-size: 36rpx; font-size: 36rpx;
color: #4772FC; color: #4772FC;
&.text-right {
text-align: right;
}
}
.contrast-wrap {
display: flex;
.contrast-text {
font-size: 22rpx;
color: #B6B7B7;
margin-right: 6rpx;
}
} }
.num-grey { .num-grey {
......
...@@ -40,9 +40,10 @@ ...@@ -40,9 +40,10 @@
<text class="tips-store">{{subItem.scene}}</text> <text class="tips-store">{{subItem.scene}}</text>
</view> </view>
<view> <view>
<view class="num-blue"><text class="f-24">¥</text>{{filter.money_three_for_two_thousands(item.curMonthTotalData[subItem.name] || 0)}} <view class="num-blue text-right"><text class="f-24">¥</text>{{filter.money_three_for_two_thousands(item.curMonthTotalData[subItem.name] || 0)}}
</view> </view>
<view wx:if="{{switchChecked}}"> <view wx:if="{{switchChecked}}" class="contrast-wrap">
<view class="contrast-text">较上月</view>
<view class="num-grey" wx:if="{{compareList[index][subItem.name] == 0 || compareList[index][subItem.name] < 1}}">0</view> <view class="num-grey" wx:if="{{compareList[index][subItem.name] == 0 || compareList[index][subItem.name] < 1}}">0</view>
<view wx:else class="{{compareList[index][subItem.name + 'Sign'] ? 'num-red' : 'num-green'}}"><text>{{compareList[index][subItem.name + 'Sign'] ? '+' : '-'}}</text>¥{{filter.money_three_for_two_thousands(compareList[index][subItem.name])}}</view> <view wx:else class="{{compareList[index][subItem.name + 'Sign'] ? 'num-red' : 'num-green'}}"><text>{{compareList[index][subItem.name + 'Sign'] ? '+' : '-'}}</text>¥{{filter.money_three_for_two_thousands(compareList[index][subItem.name])}}</view>
</view> </view>
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!