no message
Showing
11 changed files
with
198 additions
and
73 deletions
... | @@ -10,9 +10,9 @@ | ... | @@ -10,9 +10,9 @@ |
10 | @extend .shadow; | 10 | @extend .shadow; |
11 | width: 670px; | 11 | width: 670px; |
12 | margin: 0 auto; | 12 | margin: 0 auto; |
13 | min-height: 896px; | 13 | min-height: 900px; |
14 | @extend .bb; | 14 | @extend .bb; |
15 | padding: 40px 30px 30px; | 15 | padding: 20px 30px 20px; |
16 | 16 | ||
17 | .tit { | 17 | .tit { |
18 | font-size: 40px; | 18 | font-size: 40px; |
... | @@ -20,19 +20,21 @@ | ... | @@ -20,19 +20,21 @@ |
20 | } | 20 | } |
21 | 21 | ||
22 | .img-wrap { | 22 | .img-wrap { |
23 | $imgWidth: 610px; | ||
24 | $imgHeight: 480px; | ||
23 | margin: 20px 0; | 25 | margin: 20px 0; |
24 | width: 610px; | 26 | width: $imgWidth; |
25 | height: 322px; | 27 | height: $imgHeight; |
26 | border: 1px solid #F0F0F0; | 28 | border: 1px solid #F0F0F0; |
27 | border-radius: 4px; | 29 | border-radius: 4px; |
28 | 30 | ||
29 | .swiper { | 31 | .swiper { |
30 | width: 610px; | 32 | width: $imgWidth; |
31 | height: 322px; | 33 | height: $imgHeight; |
32 | 34 | ||
33 | .swiper-image { | 35 | .swiper-image { |
34 | width: 610px; | 36 | width: $imgWidth; |
35 | height: 322px; | 37 | height: $imgHeight; |
36 | } | 38 | } |
37 | } | 39 | } |
38 | } | 40 | } |
... | @@ -40,7 +42,7 @@ | ... | @@ -40,7 +42,7 @@ |
40 | .desc { | 42 | .desc { |
41 | color: #333333; | 43 | color: #333333; |
42 | font-size: 28px; | 44 | font-size: 28px; |
43 | height: 404px; | 45 | height: 320px; |
44 | line-height: 48px; | 46 | line-height: 48px; |
45 | } | 47 | } |
46 | 48 | ... | ... |
... | @@ -69,8 +69,6 @@ Page({ | ... | @@ -69,8 +69,6 @@ Page({ |
69 | defaultReceiver, | 69 | defaultReceiver, |
70 | indexInfo | 70 | indexInfo |
71 | } = this.data; | 71 | } = this.data; |
72 | console.log("indexInfo:", indexInfo); | ||
73 | console.log("item:", item); | ||
74 | if (indexInfo.memberPoints < item.commodityPrice) { | 72 | if (indexInfo.memberPoints < item.commodityPrice) { |
75 | // 积分不足 | 73 | // 积分不足 |
76 | this.setData({ | 74 | this.setData({ |
... | @@ -116,6 +114,9 @@ Page({ | ... | @@ -116,6 +114,9 @@ Page({ |
116 | item, | 114 | item, |
117 | defaultReceiver | 115 | defaultReceiver |
118 | } = this.data; | 116 | } = this.data; |
117 | console.log("item:", item); | ||
118 | console.log("defaultReceiver:", defaultReceiver); | ||
119 | |||
119 | wx.showModal({ | 120 | wx.showModal({ |
120 | title: '兑换确认', | 121 | title: '兑换确认', |
121 | content: `将花费${item.commodityPrice}兑换${item.commodityTitle}一份`, | 122 | content: `将花费${item.commodityPrice}兑换${item.commodityTitle}一份`, |
... | @@ -125,7 +126,7 @@ Page({ | ... | @@ -125,7 +126,7 @@ Page({ |
125 | url: app.api.commodityExchange, | 126 | url: app.api.commodityExchange, |
126 | data: { | 127 | data: { |
127 | commodityCode: item.commodityCode, | 128 | commodityCode: item.commodityCode, |
128 | receiverCode: defaultReceiver.receiverCode, | 129 | receiverCode: defaultReceiver && defaultReceiver.receiverCode || "", |
129 | remark: _this.data.remark | 130 | remark: _this.data.remark |
130 | } | 131 | } |
131 | }).then((result) => { | 132 | }).then((result) => { | ... | ... |
... | @@ -91,6 +91,7 @@ Page({ | ... | @@ -91,6 +91,7 @@ Page({ |
91 | this.setData({ | 91 | this.setData({ |
92 | orderSort | 92 | orderSort |
93 | }) | 93 | }) |
94 | this.resetPage(); | ||
94 | this.queryProduct(); | 95 | this.queryProduct(); |
95 | }, | 96 | }, |
96 | 97 | ||
... | @@ -102,6 +103,19 @@ Page({ | ... | @@ -102,6 +103,19 @@ Page({ |
102 | this.queryProduct(); | 103 | this.queryProduct(); |
103 | }, | 104 | }, |
104 | 105 | ||
106 | /** | ||
107 | * 我的订单 | ||
108 | */ | ||
109 | onMyOrderHandler(evt) { | ||
110 | let navIndex = getBindtapData(evt, "index"); | ||
111 | app.router.push({ | ||
112 | path: "myOrder", | ||
113 | query: { | ||
114 | navIndex: navIndex | ||
115 | } | ||
116 | }) | ||
117 | }, | ||
118 | |||
105 | bindKeyWordsInput(e) { | 119 | bindKeyWordsInput(e) { |
106 | this.setData({ | 120 | this.setData({ |
107 | keyWords: e.detail.value | 121 | keyWords: e.detail.value | ... | ... |
... | @@ -68,8 +68,44 @@ $contentWidth:690px; | ... | @@ -68,8 +68,44 @@ $contentWidth:690px; |
68 | } | 68 | } |
69 | } | 69 | } |
70 | 70 | ||
71 | |||
72 | .border { | ||
73 | width: $contentWidth; | ||
74 | @extend .shadow; | ||
75 | background-color: #ffffff; | ||
76 | @extend .bb; | ||
77 | padding: 24px 26px; | ||
78 | margin: 0 auto 20px; | ||
79 | } | ||
80 | |||
81 | // 订单区域 | ||
82 | .order { | ||
83 | display: flex; | ||
84 | justify-content: space-between; | ||
85 | font-size: 24px; | ||
86 | color: #131415; | ||
87 | text-align: center; | ||
88 | |||
89 | &-item { | ||
90 | width: 110px; | ||
91 | |||
92 | .icon-wrap { | ||
93 | @extend .fcc; | ||
94 | height: 100px; | ||
95 | height: 100px; | ||
96 | |||
97 | .icon { | ||
98 | height: 64px; | ||
99 | height: 64px; | ||
100 | } | ||
101 | } | ||
102 | |||
103 | .txt {} | ||
104 | } | ||
105 | } | ||
106 | |||
71 | .top-space { | 107 | .top-space { |
72 | height: 116px; | 108 | height: 130px; |
73 | } | 109 | } |
74 | 110 | ||
75 | .content { | 111 | .content { | ... | ... |
... | @@ -22,6 +22,39 @@ | ... | @@ -22,6 +22,39 @@ |
22 | </div> | 22 | </div> |
23 | </view> | 23 | </view> |
24 | <view class="top-space"></view> | 24 | <view class="top-space"></view> |
25 | <!-- 订单区 --> | ||
26 | <view class="border order "> | ||
27 | <view bindtap="onMyOrderHandler" data-index="0" class="order-item"> | ||
28 | <view class="icon-wrap"> | ||
29 | <image class="icon" mode="aspectFit" src="../../image/icon/icon-all-order.png" /> | ||
30 | </view> | ||
31 | <view class="txt">全部订单</view> | ||
32 | </view> | ||
33 | <view bindtap="onMyOrderHandler" data-index="1" class="order-item"> | ||
34 | <view class="icon-wrap"> | ||
35 | <image class="icon" mode="aspectFit" src="../../image/icon/icon-wait-review.png" /> | ||
36 | </view> | ||
37 | <view class="txt">待审核</view> | ||
38 | </view> | ||
39 | <view bindtap="onMyOrderHandler" data-index="2" class="order-item"> | ||
40 | <view class="icon-wrap"> | ||
41 | <image class="icon" mode="aspectFit" src="../../image/icon/icon-review-pass.png" /> | ||
42 | </view> | ||
43 | <view class="txt">已通过</view> | ||
44 | </view> | ||
45 | <view bindtap="onMyOrderHandler" data-index="3" class="order-item"> | ||
46 | <view class="icon-wrap"> | ||
47 | <image class="icon" mode="aspectFit" src="../../image/icon/icon-shipped.png" /> | ||
48 | </view> | ||
49 | <view class="txt">已发货</view> | ||
50 | </view> | ||
51 | <view bindtap="onMyOrderHandler" data-index="4" class="order-item"> | ||
52 | <view class="icon-wrap"> | ||
53 | <image class="icon" mode="aspectFit" src="../../image/icon/icon-up-pass.png" /> | ||
54 | </view> | ||
55 | <view class="txt">未通过</view> | ||
56 | </view> | ||
57 | </view> | ||
25 | <view class="content"> | 58 | <view class="content"> |
26 | <view class="product"> | 59 | <view class="product"> |
27 | <view class="product-item" wx:for="{{productList}}" wx:key="{{index}}"> | 60 | <view class="product-item" wx:for="{{productList}}" wx:key="{{index}}"> | ... | ... |
... | @@ -34,7 +34,7 @@ | ... | @@ -34,7 +34,7 @@ |
34 | <view class="line"></view> | 34 | <view class="line"></view> |
35 | <view class="cont"> | 35 | <view class="cont"> |
36 | <view class="prize"> | 36 | <view class="prize"> |
37 | <image class="image" mode="aspectFit" /> | 37 | <image class="image" mode="aspectFit" src="{{item.orderCommodityThumbnail}}" /> |
38 | </view> | 38 | </view> |
39 | <view class="detail"> | 39 | <view class="detail"> |
40 | <view class="t1">{{item.orderCommodityTitle}}</view> | 40 | <view class="t1">{{item.orderCommodityTitle}}</view> | ... | ... |
... | @@ -46,6 +46,7 @@ Page({ | ... | @@ -46,6 +46,7 @@ Page({ |
46 | this.setData({ | 46 | this.setData({ |
47 | rankInfo: rankInfo | 47 | rankInfo: rankInfo |
48 | }) | 48 | }) |
49 | console.log("rankInfo 1:", rankInfo); | ||
49 | resolve(); | 50 | resolve(); |
50 | }) | 51 | }) |
51 | }); | 52 | }); |
... | @@ -72,7 +73,7 @@ Page({ | ... | @@ -72,7 +73,7 @@ Page({ |
72 | this.setData({ | 73 | this.setData({ |
73 | historyRankInfoList: historyRankInfoList | 74 | historyRankInfoList: historyRankInfoList |
74 | }) | 75 | }) |
75 | console.log("historyRankInfoList:", historyRankInfoList); | 76 | console.log("rankInfo 2:", historyRankInfoList); |
76 | this.setHistory(); | 77 | this.setHistory(); |
77 | resolve(); | 78 | resolve(); |
78 | }) | 79 | }) |
... | @@ -141,7 +142,12 @@ Page({ | ... | @@ -141,7 +142,12 @@ Page({ |
141 | this.setData({ | 142 | this.setData({ |
142 | turnsIndex: curIndex | 143 | turnsIndex: curIndex |
143 | }); | 144 | }); |
144 | this.queryActivityHistory(); | 145 | console.log("curIndex:", curIndex); |
146 | if (curIndex == 0) { | ||
147 | this.queryActivity(); | ||
148 | } else { | ||
149 | this.queryActivityHistory(); | ||
150 | } | ||
145 | } | 151 | } |
146 | 152 | ||
147 | }, | 153 | }, | ... | ... |
... | @@ -77,7 +77,7 @@ $contentWidth:690px; | ... | @@ -77,7 +77,7 @@ $contentWidth:690px; |
77 | justify-content: space-between; | 77 | justify-content: space-between; |
78 | 78 | ||
79 | &-item { | 79 | &-item { |
80 | width: 50%; | 80 | width: 60%; |
81 | 81 | ||
82 | // 本轮排行 | 82 | // 本轮排行 |
83 | .pubish { | 83 | .pubish { |
... | @@ -137,6 +137,10 @@ $contentWidth:690px; | ... | @@ -137,6 +137,10 @@ $contentWidth:690px; |
137 | padding: 10px 32px; | 137 | padding: 10px 32px; |
138 | } | 138 | } |
139 | } | 139 | } |
140 | |||
141 | &-item2 { | ||
142 | width: 40%; | ||
143 | } | ||
140 | } | 144 | } |
141 | 145 | ||
142 | // 标题 | 146 | // 标题 | ... | ... |
... | @@ -46,7 +46,7 @@ | ... | @@ -46,7 +46,7 @@ |
46 | </picker> | 46 | </picker> |
47 | </view> | 47 | </view> |
48 | </view> | 48 | </view> |
49 | <view class="rank-func-item pubish fje"> | 49 | <view class="rank-func-item rank-func-item2 pubish fje"> |
50 | <view wx:if="{{turnsIndex == 0}}" data-index="1" bindtap="onChangeTurnsHandler" class="mode"> | 50 | <view wx:if="{{turnsIndex == 0}}" data-index="1" bindtap="onChangeTurnsHandler" class="mode"> |
51 | 查看历史排行 | 51 | 查看历史排行 |
52 | </view> | 52 | </view> | ... | ... |
... | @@ -61,7 +61,7 @@ $contentWidth: 690px; | ... | @@ -61,7 +61,7 @@ $contentWidth: 690px; |
61 | border-radius: 8px; | 61 | border-radius: 8px; |
62 | } | 62 | } |
63 | 63 | ||
64 | .vip-check{ | 64 | .vip-check { |
65 | background: #6DD400; | 65 | background: #6DD400; |
66 | } | 66 | } |
67 | } | 67 | } |
... | @@ -155,24 +155,37 @@ $contentWidth: 690px; | ... | @@ -155,24 +155,37 @@ $contentWidth: 690px; |
155 | justify-content: space-between; | 155 | justify-content: space-between; |
156 | 156 | ||
157 | &-item { | 157 | &-item { |
158 | width: 68px; | 158 | display: flex; |
159 | height: 100px; | 159 | // align-items: center; |
160 | border-radius: 8px; | ||
161 | text-align: center; | ||
162 | background: #F0F0F0; | ||
163 | padding: 8px 4px; | ||
164 | @extend .bb; | ||
165 | 160 | ||
166 | .no { | 161 | .line { |
167 | @extend .fcc; | 162 | background: #F0F0F0; |
168 | color: #333333; | 163 | width: 46px; |
169 | font-size: 28px; | 164 | height: 2px; |
170 | height: 40px; | 165 | margin-top: 26px; |
171 | } | 166 | } |
172 | 167 | ||
173 | .icon { | 168 | .day { |
174 | image { | 169 | text-align: center; |
175 | margin-top: 4px; | 170 | |
171 | .circle { | ||
172 | background: #F0F0F0; | ||
173 | width: 52px; | ||
174 | height: 52px; | ||
175 | line-height: 52px; | ||
176 | border-radius: 26px; | ||
177 | font-size: 28px; | ||
178 | color: #FFFFFF; | ||
179 | } | ||
180 | |||
181 | .num { | ||
182 | font-size: 24px; | ||
183 | color: #3680EB; | ||
184 | margin-top: 6px; | ||
185 | } | ||
186 | |||
187 | .icon { | ||
188 | margin-top: 6px; | ||
176 | width: 40px; | 189 | width: 40px; |
177 | height: 40px; | 190 | height: 40px; |
178 | } | 191 | } |
... | @@ -180,13 +193,51 @@ $contentWidth: 690px; | ... | @@ -180,13 +193,51 @@ $contentWidth: 690px; |
180 | } | 193 | } |
181 | 194 | ||
182 | &-item-act { | 195 | &-item-act { |
183 | color: #FFFFFF; | 196 | .line { |
184 | background: #3680EB; | 197 | background: #3680EB; |
198 | } | ||
199 | |||
200 | .day { | ||
201 | .circle { | ||
202 | background: #3680EB; | ||
203 | } | ||
185 | 204 | ||
186 | .no { | ||
187 | color: #ffffff; | ||
188 | } | 205 | } |
189 | } | 206 | } |
207 | |||
208 | // &-item { | ||
209 | // width: 68px; | ||
210 | // height: 100px; | ||
211 | // border-radius: 8px; | ||
212 | // text-align: center; | ||
213 | // background: #F0F0F0; | ||
214 | // padding: 8px 4px; | ||
215 | // @extend .bb; | ||
216 | |||
217 | // .no { | ||
218 | // @extend .fcc; | ||
219 | // color: #333333; | ||
220 | // font-size: 28px; | ||
221 | // height: 40px; | ||
222 | // } | ||
223 | |||
224 | // .icon { | ||
225 | // image { | ||
226 | // margin-top: 4px; | ||
227 | // width: 40px; | ||
228 | // height: 40px; | ||
229 | // } | ||
230 | // } | ||
231 | // } | ||
232 | |||
233 | // &-item-act { | ||
234 | // color: #FFFFFF; | ||
235 | // background: #3680EB; | ||
236 | |||
237 | // .no { | ||
238 | // color: #ffffff; | ||
239 | // } | ||
240 | // } | ||
190 | } | 241 | } |
191 | 242 | ||
192 | // 签到按钮 | 243 | // 签到按钮 |
... | @@ -198,7 +249,8 @@ $contentWidth: 690px; | ... | @@ -198,7 +249,8 @@ $contentWidth: 690px; |
198 | font-size: 28px; | 249 | font-size: 28px; |
199 | color: #FFFFFF; | 250 | color: #FFFFFF; |
200 | } | 251 | } |
201 | &-btn-disable{ | 252 | |
253 | &-btn-disable { | ||
202 | background: #ECECEC; | 254 | background: #ECECEC; |
203 | } | 255 | } |
204 | } | 256 | } | ... | ... |
... | @@ -48,7 +48,7 @@ | ... | @@ -48,7 +48,7 @@ |
48 | </view> | 48 | </view> |
49 | </view> | 49 | </view> |
50 | <!-- 7天签到 --> | 50 | <!-- 7天签到 --> |
51 | <view class="check"> | 51 | <!-- <view class="check"> |
52 | <view wx:for="{{signInfo}}" wx:key="{{index}}" class="check-item {{item ? 'check-item-act' :''}}"> | 52 | <view wx:for="{{signInfo}}" wx:key="{{index}}" class="check-item {{item ? 'check-item-act' :''}}"> |
53 | <view class="no">{{index+1}}</view> | 53 | <view class="no">{{index+1}}</view> |
54 | <view class="icon"> | 54 | <view class="icon"> |
... | @@ -57,44 +57,21 @@ | ... | @@ -57,44 +57,21 @@ |
57 | <image wx:else mode="aspectFit" src="../../image/icon/icon-integral.png" /> | 57 | <image wx:else mode="aspectFit" src="../../image/icon/icon-integral.png" /> |
58 | </view> | 58 | </view> |
59 | </view> | 59 | </view> |
60 | </view> --> | ||
61 | <view class="check"> | ||
62 | <view wx:for="{{signInfo}}" wx:key="{{index}}" class="check-item {{item ? 'check-item-act' :''}}"> | ||
63 | <view wx:if="{{index != 0}}" class="line"></view> | ||
64 | <view class="day"> | ||
65 | <view class="circle">{{index+1}}</view> | ||
66 | <view wx:if="{{index != signInfo.length-1}}" class="num">+10</view> | ||
67 | <image wx:else class="icon" mode="aspectFit" src="../../image/icon/icon-red-package.png" /> | ||
68 | </view> | ||
69 | </view> | ||
60 | </view> | 70 | </view> |
61 | <!-- 签到按钮 --> | 71 | <!-- 签到按钮 --> |
62 | <view wx:if="{{userInfo.isSign == 1}}" class="sign-btn sign-btn-disable">已签到</view> | 72 | <view wx:if="{{userInfo.isSign == 1}}" class="sign-btn sign-btn-disable">已签到</view> |
63 | <view wx:else class="sign-btn" bindtap="onSignHandler">签到 (第{{signNum}}天)</view> | 73 | <view wx:else class="sign-btn" bindtap="onSignHandler">签到 (第{{signNum}}天)</view> |
64 | </view> | 74 | </view> |
65 | <!-- 订单区 --> | ||
66 | <view class="border order "> | ||
67 | <view bindtap="onMyOrderHandler" data-index="0" class="order-item"> | ||
68 | <view class="icon-wrap"> | ||
69 | <image class="icon" mode="aspectFit" src="../../image/icon/icon-all-order.png" /> | ||
70 | </view> | ||
71 | <view class="txt">全部订单</view> | ||
72 | </view> | ||
73 | <view bindtap="onMyOrderHandler" data-index="1" class="order-item"> | ||
74 | <view class="icon-wrap"> | ||
75 | <image class="icon" mode="aspectFit" src="../../image/icon/icon-wait-review.png" /> | ||
76 | </view> | ||
77 | <view class="txt">待审核</view> | ||
78 | </view> | ||
79 | <view bindtap="onMyOrderHandler" data-index="2" class="order-item"> | ||
80 | <view class="icon-wrap"> | ||
81 | <image class="icon" mode="aspectFit" src="../../image/icon/icon-review-pass.png" /> | ||
82 | </view> | ||
83 | <view class="txt">已通过</view> | ||
84 | </view> | ||
85 | <view bindtap="onMyOrderHandler" data-index="3" class="order-item"> | ||
86 | <view class="icon-wrap"> | ||
87 | <image class="icon" mode="aspectFit" src="../../image/icon/icon-shipped.png" /> | ||
88 | </view> | ||
89 | <view class="txt">已发货</view> | ||
90 | </view> | ||
91 | <view bindtap="onMyOrderHandler" data-index="4" class="order-item"> | ||
92 | <view class="icon-wrap"> | ||
93 | <image class="icon" mode="aspectFit" src="../../image/icon/icon-up-pass.png" /> | ||
94 | </view> | ||
95 | <view class="txt">未通过</view> | ||
96 | </view> | ||
97 | </view> | ||
98 | <!-- 功能区 --> | 75 | <!-- 功能区 --> |
99 | <view class="border func"> | 76 | <view class="border func"> |
100 | <view class="my-qrcode"> | 77 | <view class="my-qrcode"> | ... | ... |
-
Please register or sign in to post a comment