index.wxml
7.94 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
<!-- src引入filter.wxs, module给模块起名 -->
<wxs src="../index.wxs" module="filter" />
<navigation-bar bindnavbarReady="navbarReady" showWhiteMenu showMenu="{{ true }}" bindback="back" bindshowMenuPopup="showMenuPopup" navStyle="{{ navStyle }}">
<view class="navigation-title">
<view class="navigation-title-text text-hide">{{userInfo.shopMerchantName || '全部'}}</view>
<!-- <view class="arrow" wx:if="{{ userInfo.isSuper }}">
<image src="/images/arrow-bottom.png" />
</view> -->
</view>
</navigation-bar>
<view class="bg"></view>
<view style="height:100vh;overflow: hidden;">
<view class="layout {{ flag?'opacity':''}} {{waitInputCount?'mtTips':'' }}" style="height:calc(100vh - {{ navBarHeight}}px); margin-top:{{ navBarHeight + 'px' }}">
<block wx:if="{{ navBarHeight > 0 }}">
<view class="tips">
<view class="tips-text text-hide">
你好,
<text>{{loginRoleLabel[loginRole]|| ''}}{{userInfo.name || ''}}</text>
</view>
<!-- <view class="change_box">
<view class="change_btn {{changeSelectIndex == index ? 'active' : ''}}" bindtap="changeStaticData" data-index="{{index}}" wx:for="{{changeBtnData}}" wx:key="index" wx:for-index="index">{{item.label}}</view>
</view> -->
</view>
<view class="swiper-wrap">
<swiper bindchange="changeSwiper">
<block wx:for="{{ 3 }}" wx:key="index">
<swiper-item>
<view class="swiper-item">
<view class="total-wrap">
<view class="item left">
<view class="title">{{changeSelectIndex==0?'今日':changeSelectIndex==1?'本月':'累计'}}产值</view>
<veiw class="number" wx:if="{{ userInfo.userType == 2 && !(userInfo.isSuper|| userInfo.loginRole ==3) }}">
<text class="unit">¥</text>
<text>{{userStat[changeBtnData[changeSelectIndex].valueObj].totalOrderMoney||0}}</text>
</veiw>
<veiw class="number" wx:else>
<text class="unit">¥</text>
<text>{{userStat[changeBtnData[changeSelectIndex].valueFn].totalOrderMoney||0}}</text>
</veiw>
</view>
<view class="item">
<view class="title">转化率</view>
<view class="number" wx:if="{{ userInfo.userType == 2 && !(userInfo.isSuper|| userInfo.loginRole ==3) }}">
<text>{{userStat[changeBtnData[changeSelectIndex].valueObj].upgradeRate||0}}</text>
<text class="units">%</text>
</view>
<view class="number" wx:else>
<text>{{userStat[changeBtnData[changeSelectIndex].valueFn].upgradeRate||0}}</text>
<text class="units">%</text>
</view>
</view>
</view>
<view class="custom-statistic">
<view class="customItem" wx:for="{{ totalList }}" data-item="{{ item }}" bindtap="navTabPage" wx:key="index">
<block wx:if="{{ item.index==2 }}">
<view class="label">
<text>{{item.name}} </text>
<text data-item="{{ item }}" catchtap="navTabPage" data-type="wait">/{{item.waitname}}</text>
</view>
<view class="number">
<view class="firstValue">{{userStat[changeBtnData[changeSelectIndex].valueObj][item.itemName]||0}}</view>
<view class="lastValue">/{{userStat[changeBtnData[changeSelectIndex].valueObj][item.waititemName]||0}}</view>
</view>
</block>
<block wx:else>
<view class="label">{{item.name}}</view>
<view class="number" wx:if="{{ userInfo.userType == 2 && !(userInfo.isSuper|| userInfo.loginRole ==3) }}">
<text class="unit" wx:if="{{ item.unit }}">{{item.unit}}</text>
<view>{{userStat[changeBtnData[changeSelectIndex].valueObj][item.itemName]||0}}</view>
</view>
<view class="number" wx:else>
<text class="unit" wx:if="{{ item.unit }}">{{item.unit}}</text>
<view>{{userStat[changeBtnData[changeSelectIndex].valueFn][item.itemName]||0}}</view>
</view>
</block>
</view>
</view>
</view>
</swiper-item>
</block>
</swiper>
<view class="dots">
<view wx:for="{{ 3 }}" wx:key="item" wx:for-index="idx" class="dot {{ changeSelectIndex==idx?'active':'' }}"></view>
</view>
</view>
<block wx:if="{{ !isNoStaff }}">
<div class="menu">
<block wx:for="{{ menu }}" wx:key="index">
<view class="item" bindtap="jump" data-item="{{ item }}" data-type="{{ userInfo.userType }}">
<image src="{{ IMG_URL}}upgrade/{{item.icon }}.png" />
<view class="label">{{item.name}}</view>
<view class="hot_icon" wx:if="{{ item.hot }}">热</view>
<view class="hot_icon" wx:if="{{ item.tipsNum }}">{{item.tipsNum}}</view>
<view class="bubble_icon" wx:if="{{ item.noRead }}"></view>
</view>
</block>
</div>
</block>
<block wx:if="{{ isNoStaff }}">
<div class="menu noStaff">
<block wx:for="{{ menu }}" wx:key="index">
<view class="item" bindtap="jump" data-item="{{ item }}" data-type="{{ userInfo.userType }}">
<image src="{{ IMG_URL}}upgrade/{{item.icon }}.png" />
<view class="label">{{item.name}}</view>
<view class="hot_icon" wx:if="{{ item.tipsNum }}">{{item.tipsNum}}</view>
</view>
</block>
</div>
</block>
<block wx:if="{{ !isNoStaff }}">
<div class="menu" wx:if="{{ newMenu.length>0 }}">
<block wx:for="{{ newMenu }}" wx:key="index">
<view class="item" bindtap="jump" data-item="{{ item }}" data-type="{{ userInfo.userType }}">
<image src="{{ IMG_URL}}upgrade/{{item.icon }}.png" />
<view class="label">{{item.name}}</view>
<view class="hot_icon" wx:if="{{ item.hot }}">热</view>
<view class="hot_icon" wx:if="{{ item.tipsNum }}">{{item.tipsNum}}</view>
<view class="bubble_icon" wx:if="{{ item.noRead }}"></view>
</view>
</block>
</div>
</block>
</block>
</view>
</view>
<modal id="modal2" class="modal" custom="true" btns="{{ ['取消','确定'] }}">
<view class="modatcontent">
<view class="modalbox {{ selectType == 1?'act': '' }} com" bindtap="selectType" data-type="1">
<gl-image class="icon" src="/miniProgram/order1.png"></gl-image>
新增工单
</view>
<view class="modalbox cancle {{ selectType == 2?'act': '' }}" bindtap="selectType" data-type="2">
<gl-image class="icon" src="/miniProgram/order3.png"></gl-image>
战败下单
</view>
</view>
</modal>
<recording-order-popup wx:if="{{ showOrderpop }}" show="{{ showOrderpop }}" bind:success="navigator" title="请选择交易参考号" />
<block wx:if="{{ userInfo.isSuper || userInfo.loginRole== 3 || userInfo.loginRole== 5 }}">
<side-select-by-page-popup show="{{ shopSideSelectPopup }}" bindconfirm="storeSearchEvent" subIndex="{{ subIndex }}" hasTabBar="true" />
</block>
<block wx:else>
<side-select-popup show="{{ shopSideSelectPopup }}" storeList="{{ storeRange }}" bindconfirm="storeSearchEvent" subIndex="{{ subIndex }}" hasTabBar="true" />
</block>
<task-dialog wx:if="{{ showTaskDialog }}" showDialog="{{ showTaskDialog }}" taskInfo="{{ taskInfo }}"></task-dialog>