Commit 80b4ad922c13fdbd4d6afc66099062edb1860651
1 parent
7fb3975a
1.我的礼包的优化,
Showing
6 changed files
with
87 additions
and
9 deletions
components/qr_code/qr_code.wxss
@@ -90,14 +90,14 @@ top: 5rpx; | @@ -90,14 +90,14 @@ top: 5rpx; | ||
90 | .qrcode{ | 90 | .qrcode{ |
91 | width:520rpx; | 91 | width:520rpx; |
92 | height:520rpx; | 92 | height:520rpx; |
93 | - margin-top:-27rpx | 93 | + margin-top:-18rpx |
94 | 94 | ||
95 | 95 | ||
96 | } | 96 | } |
97 | .r-code{ | 97 | .r-code{ |
98 | font-size:28rpx; | 98 | font-size:28rpx; |
99 | - padding-left: 25rpx; | ||
100 | -margin-top: -5.5rpx; | 99 | + margin-top: -5.5rpx; |
100 | + text-align: center; | ||
101 | 101 | ||
102 | } | 102 | } |
103 | 103 |
packageA/pages/myGift/myGift.js
@@ -315,5 +315,19 @@ Page({ | @@ -315,5 +315,19 @@ Page({ | ||
315 | 315 | ||
316 | }) | 316 | }) |
317 | }, | 317 | }, |
318 | + | ||
319 | + | ||
320 | + show_remark:function(e){ | ||
321 | + var index=e.currentTarget.dataset.index; | ||
322 | + var item=this.data.list.pageData[index]; | ||
323 | + this.setData({ | ||
324 | + show_rem_pop:1, | ||
325 | + pop_remark_text:item.lbintro | ||
326 | + }) | ||
327 | + }, | ||
328 | + | ||
329 | + close_remark:function(){ | ||
330 | + this.setData({show_rem_pop:0,}) | ||
331 | + } | ||
318 | 332 | ||
319 | }) | 333 | }) |
320 | \ No newline at end of file | 334 | \ No newline at end of file |
packageA/pages/myGift/myGift.wxml
@@ -8,7 +8,10 @@ | @@ -8,7 +8,10 @@ | ||
8 | <view class="tab-item" wx:for="{{list.pageData}}"> | 8 | <view class="tab-item" wx:for="{{list.pageData}}"> |
9 | <view bindtap="goto" data-url="{{'/packageA/pages/myGiftDetails/myGiftDetails?index=0&id=' + item.id}}"> | 9 | <view bindtap="goto" data-url="{{'/packageA/pages/myGiftDetails/myGiftDetails?index=0&id=' + item.id}}"> |
10 | <!-- 图片 --> | 10 | <!-- 图片 --> |
11 | - <view class="img-container"><image src="{{imghost + (item.lburl ? item.lburl:'miniapp/images/default_g_img.gif')}}" class="img" mode="widthFix"/></view> | 11 | + <view class="img-container rel"> |
12 | + <image src="{{imghost + (item.lburl ? item.lburl:'miniapp/images/default_g_img.gif')}}" class="img" mode="widthFix"/> | ||
13 | + <view catchtap="show_remark" data-index="{{index}}" class="lb_remark ellipsis-1" wx:if="{{item.lbintro}}">活动说明:{{item.lbintro}}</view> | ||
14 | + </view> | ||
12 | <view class="desc-container"> | 15 | <view class="desc-container"> |
13 | <!-- 标题 --> | 16 | <!-- 标题 --> |
14 | <view class="mgb10 ellipsis-2 lh taj">{{item.lbtitle}}</view> | 17 | <view class="mgb10 ellipsis-2 lh taj">{{item.lbtitle}}</view> |
@@ -53,9 +56,10 @@ | @@ -53,9 +56,10 @@ | ||
53 | <view class="mgb10 ellipsis-2 lh taj">{{item.lbtitle}}</view> | 56 | <view class="mgb10 ellipsis-2 lh taj">{{item.lbtitle}}</view> |
54 | <!-- 时间 --> | 57 | <!-- 时间 --> |
55 | <view class="date pdb20">兑换截止日期 {{filter.format_time(item.endtime)}}</view> | 58 | <view class="date pdb20">兑换截止日期 {{filter.format_time(item.endtime)}}</view> |
59 | + <view catchtap="show_remark" data-index="{{index}}" wx:if="{{item.lbintro}}" class="date pdb20">活动说明</view> | ||
56 | </view> | 60 | </view> |
57 | <!-- 说明 --> | 61 | <!-- 说明 --> |
58 | - <!-- <view class="c-red fs24">*请到线下门店兑换</view> --> | 62 | + <view wx:if="{{item.lbtype==1}}" class="c-red fs24">注:请到线下门店兑换</view> |
59 | </view> | 63 | </view> |
60 | </view> | 64 | </view> |
61 | </block> | 65 | </block> |
@@ -68,3 +72,13 @@ | @@ -68,3 +72,13 @@ | ||
68 | <!-- 引入提示组件 --> | 72 | <!-- 引入提示组件 --> |
69 | <warn id="warn"></warn> | 73 | <warn id="warn"></warn> |
70 | <my_confirm id="my_confirm"></my_confirm> | 74 | <my_confirm id="my_confirm"></my_confirm> |
75 | +<view wx:if="{{show_rem_pop}}"> | ||
76 | + <view class="cover-layer" bindtap="close_remark"></view> | ||
77 | + <view class="rem_pop;"> | ||
78 | + <view style="text-align: right;"bindtap="close_remark"><text class="iconfont icon-close" style="font-size: 40rpx;"></text></view> | ||
79 | + <view style="padding: 0 16rpx;"> | ||
80 | + <view class="fs32">活动说明:</view> | ||
81 | + <view class="fs30">{{pop_remark_text}}</view> | ||
82 | + </view> | ||
83 | + </view> | ||
84 | +</view> | ||
71 | \ No newline at end of file | 85 | \ No newline at end of file |
packageA/pages/myGift/myGift.wxss
@@ -164,4 +164,28 @@ page { | @@ -164,4 +164,28 @@ page { | ||
164 | color: #bbb; | 164 | color: #bbb; |
165 | text-align: center; | 165 | text-align: center; |
166 | font-size: 22rpx; | 166 | font-size: 22rpx; |
167 | -} | ||
168 | \ No newline at end of file | 167 | \ No newline at end of file |
168 | +} | ||
169 | +.lb_remark{ | ||
170 | + position: absolute; | ||
171 | + bottom: 0; | ||
172 | + left: 0; | ||
173 | + width: 100%; | ||
174 | + height: 50rpx; | ||
175 | + line-height: 50rpx; | ||
176 | + font-size: 30rpx; | ||
177 | + color: #333; | ||
178 | + padding-left: 10rpx; | ||
179 | + background-color: rgba(250,250,250,0.5); | ||
180 | +} | ||
181 | + | ||
182 | +.rem_pop{ | ||
183 | + position: fixed; | ||
184 | + top: 30%; | ||
185 | + left: 6%; | ||
186 | + width: 88%; | ||
187 | + margin: 0 auto; | ||
188 | + height: 460rpx; | ||
189 | + background-color: #fff; | ||
190 | + z-index: 100; border-radius: 10rpx; | ||
191 | + padding: 10rpx; | ||
192 | +} |
packageA/pages/myGiftDetails/myGiftDetails.js
packageA/pages/myGiftDetails/myGiftDetails.wxml
@@ -71,14 +71,40 @@ | @@ -71,14 +71,40 @@ | ||
71 | </view> | 71 | </view> |
72 | 72 | ||
73 | <view wx:if="{{details.lbtype==2}}" class="flex" style="flex-wrap: wrap;"> | 73 | <view wx:if="{{details.lbtype==2}}" class="flex" style="flex-wrap: wrap;"> |
74 | - <block wx:for="{{list}}"> | 74 | + <block wx:for="{{list}}" wx:for-index="f_idx"> |
75 | + <block wx:for="{{item.goods_num-0}}" wx:for-item="nitem" wx:for-index="idx"> | ||
75 | <view class="lb_quan" style="background-image: url({{imghost}}/miniapp/images/yhq_{{index%2+1}}.png)"> | 76 | <view class="lb_quan" style="background-image: url({{imghost}}/miniapp/images/yhq_{{index%2+1}}.png)"> |
76 | <view class="flex fs28 fir_view"> | 77 | <view class="flex fs28 fir_view"> |
77 | <view>满{{item.condition}}使用</view> | 78 | <view>满{{item.condition}}使用</view> |
78 | <view class="fs8" style="text-align: right">¥{{item.money}}</view> | 79 | <view class="fs8" style="text-align: right">¥{{item.money}}</view> |
79 | </view> | 80 | </view> |
80 | - <view style="font-size: 16rpx; text-align: center">活动结束日期{{filter.format_time(item.use_end_time,1)}}</view> | 81 | + |
82 | + | ||
83 | + <view style="font-size: 16rpx; text-align: center"> {{index==0?'活动结束日期':'截至时间'}}: | ||
84 | + | ||
85 | + <block wx:if="{{item.endtype<1}}"> | ||
86 | + <block wx:if="{{item.use_end_time}}"> | ||
87 | + {{filter.format_time(item.use_end_time,1)}} | ||
88 | + </block> | ||
89 | + <block wx:else> | ||
90 | + 不限 | ||
91 | + </block> | ||
92 | + </block> | ||
93 | + | ||
94 | + <block wx:else> | ||
95 | + <block wx:if="{{item.days>0}}"> | ||
96 | + 有效期{{item.days}}天 | ||
97 | + </block> | ||
98 | + <block wx:else> | ||
99 | + 不限 | ||
100 | + </block> | ||
101 | + | ||
102 | + </block> | ||
103 | + </view> | ||
104 | + | ||
105 | + | ||
81 | </view> | 106 | </view> |
107 | + </block> | ||
82 | </block> | 108 | </block> |
83 | </view> | 109 | </view> |
84 | 110 |