Commit 35fc3332224c56cb2344149633faf289f78af1ca
合并解决冲突
Showing
6 changed files
with
93 additions
and
15 deletions
components/diy_public/diy_public.js
... | ... | @@ -50,9 +50,11 @@ Component({ |
50 | 50 | '2':"/miniapp/images/component/pingd/pingd.png", |
51 | 51 | '6':"/miniapp/images/component/pingd/pingd.png", |
52 | 52 | '8':"/miniapp/images/component/presale.png", |
53 | + '9':"/miniapp/images/component/luckyactivity.png", | |
53 | 54 | }, |
54 | 55 | nav1:'/packageA/pages/goodsInfo/goodsInfo?', |
55 | 56 | nav2:'/pages/goods/goodsInfo/goodsInfo?', |
57 | + | |
56 | 58 | }, |
57 | 59 | |
58 | 60 | pageLifetimes: { |
... | ... | @@ -98,7 +100,7 @@ Component({ |
98 | 100 | prom_text:'已团', |
99 | 101 | nav1:'/pages/goods/goodsInfo/goodsInfo?', |
100 | 102 | nav2:'/pages/goods/goodsInfo/goodsInfo?' |
101 | - }) | |
103 | + }) | |
102 | 104 | } |
103 | 105 | if (this.data.prom_type==8) { //预售 |
104 | 106 | this.setData({ |
... | ... | @@ -107,6 +109,14 @@ Component({ |
107 | 109 | nav2:'/packageC/pages/presell/goodsInfo/goodsInfo?' |
108 | 110 | }) |
109 | 111 | } |
112 | + if (this.data.prom_type==9) { //幸运购 | |
113 | + this.setData({ | |
114 | + prom_text:'已售', | |
115 | + nav1:'/packageC/pages/luckyGo/luckyGo_goodsInfo/luckyGo_goodsInfo?', | |
116 | + nav2:'/packageC/pages/luckyGo/luckyGo_goodsInfo/luckyGo_goodsInfo?' | |
117 | + }) | |
118 | + } | |
119 | + | |
110 | 120 | var g_id = this.data.object; |
111 | 121 | |
112 | 122 | this.init(g_id); |
... | ... | @@ -165,6 +175,10 @@ Component({ |
165 | 175 | gUrl="/api/weshop/marketing/marketingPresellList/page?store_id=" |
166 | 176 | +os.stoid+"&goodsidlist="+goodsidlist + "&user_id="+user_id+'&is_end=0&timetype=3&isuse=1'; |
167 | 177 | } |
178 | + if (th.data.prom_type==9) { //幸运购 | |
179 | + gUrl="/api/weshop/prom/luckyActivity/getGoodsList?store_id=" | |
180 | + +os.stoid+"&goodsidlist="+goodsidlist + "&user_id="+user_id+'&is_end=0&timetype=1&type=1'; | |
181 | + } | |
168 | 182 | |
169 | 183 | |
170 | 184 | |
... | ... | @@ -226,6 +240,18 @@ Component({ |
226 | 240 | pageSize:9 |
227 | 241 | } |
228 | 242 | } |
243 | + if (this.data.prom_type==9) { //幸运购 | |
244 | + gUrl="/api/weshop/prom/luckyActivity/page" | |
245 | + req={ | |
246 | + store_id:os.stoid, | |
247 | + is_end:0, | |
248 | + timetype:1, | |
249 | + // isuse:1, | |
250 | + // page:1, | |
251 | + // user_id:user_id, | |
252 | + // pageSize:9 | |
253 | + } | |
254 | + } | |
229 | 255 | |
230 | 256 | getApp().request.promiseGet(gUrl, |
231 | 257 | { isShowLoading: 1, data:req } |
... | ... | @@ -244,6 +270,7 @@ Component({ |
244 | 270 | let prom_type=this.data.prom_type |
245 | 271 | goodslist.forEach(function (vy, indy) { |
246 | 272 | if(!vy.id) vy.id=vy.prom_id; |
273 | + if(vy.title && !vy.goods_name) vy.goods_name=vy.title; | |
247 | 274 | }) |
248 | 275 | |
249 | 276 | // 判断火热,预热 |
... | ... | @@ -279,7 +306,7 @@ Component({ |
279 | 306 | |
280 | 307 | |
281 | 308 | var promisies = []; |
282 | - if (th.data.prom_type !=8) { | |
309 | + if (th.data.prom_type !=8 && th.data.prom_type !=9) { | |
283 | 310 | for (const key in all_array) { |
284 | 311 | if (Object.hasOwnProperty.call(all_array, key)) { |
285 | 312 | const val = all_array[key]; |
... | ... | @@ -306,6 +333,7 @@ Component({ |
306 | 333 | }; |
307 | 334 | // let price=all_array[i].price.toFixed(2) |
308 | 335 | let price=all_array[i].price + '' |
336 | + | |
309 | 337 | if (th.data.prom_type==8) { //预售 |
310 | 338 | price = all_array[i].presell_price + '' |
311 | 339 | if (all_array[i].status ===0) { |
... | ... | @@ -315,8 +343,12 @@ Component({ |
315 | 343 | all_array[i].goods_num=all_array[i].presell_sumqty*1 + all_array[i].virtual_qty*1 |
316 | 344 | all_array[i].buy_num=all_array[i].buy_goodnum + all_array[i].virtual_qty*1 |
317 | 345 | } |
318 | - | |
319 | - | |
346 | + } | |
347 | + if (th.data.prom_type==9) { //幸运购 | |
348 | + price = (all_array[i].group_price / 100) + '' | |
349 | + // all_array[i].buy_num = all_array[i].group_joined | |
350 | + all_array[i].buy_num = all_array[i].goods_num*1 - all_array[i].actLen*1 | |
351 | + all_array[i].goods_name = all_array[i].title | |
320 | 352 | } |
321 | 353 | |
322 | 354 | |
... | ... | @@ -329,6 +361,12 @@ Component({ |
329 | 361 | } |
330 | 362 | |
331 | 363 | all_array[i].residue=all_array[i].goods_num*1 - all_array[i].buy_num*1 |
364 | + all_array[i].residue = (all_array[i].residue >= 0) ? all_array[i].residue : 0 | |
365 | + if (th.data.prom_type==9) { //幸运购 | |
366 | + all_array[i].residue= all_array[i].actLen | |
367 | + } | |
368 | + | |
369 | + // console.error(all_array[i].residue); | |
332 | 370 | if (all_array[i].residue && all_array[i].residue > 0 && all_array[i].status !=2) { |
333 | 371 | empty.push(all_array[i]) |
334 | 372 | } |
... | ... | @@ -438,7 +476,14 @@ Component({ |
438 | 476 | sec: '00' |
439 | 477 | } |
440 | 478 | } |
441 | - var txt = "goods_array[" + j + "][" + i + "].djs"; | |
479 | + let txt = "goods_array[" + j + "][" + i + "].djs"; | |
480 | + | |
481 | + if (!o.status && obj.day=='00' && obj.hou=='00' && obj.min=='00' && obj.sec=='01') { | |
482 | + let t1="goods_array[" + j + "][" + i + "].status"; | |
483 | + ee.setData({ | |
484 | + [t1]:1 | |
485 | + }) | |
486 | + } | |
442 | 487 | ee.setData({ |
443 | 488 | [txt]: obj |
444 | 489 | }); |
... | ... | @@ -464,6 +509,9 @@ Component({ |
464 | 509 | if (this.data.prom_type==8) { //预售 |
465 | 510 | url="/packageC/pages/presell/list/list"; |
466 | 511 | } |
512 | + if (this.data.prom_type==9) { //幸运购 | |
513 | + url="/packageC/pages/luckyGo/luckyGo_activityList/luckyGo_activityList"; | |
514 | + } | |
467 | 515 | |
468 | 516 | wx.navigateTo({ |
469 | 517 | url | ... | ... |
components/diy_public/diy_public.wxml
... | ... | @@ -16,7 +16,7 @@ |
16 | 16 | <view style="{{'padding-left:'+object.page_margins+'px;padding-right:'+object.page_margins+'px;'}}" class="{{'new_item1_box '+ ((object.product_style==1 || object.product_style==3 )? ' bgf ':'')}}"> |
17 | 17 | <block wx:for="{{goods_array}}"> |
18 | 18 | <view wx:for="{{item}}" wx:for-item="aitem" wx:for-index="aind" class="{{'new_item1 ' + (object.product_style==2 ? ' boxsha ':'') + (object.product_style==3 ? ' aborder ':'') + ((object.product_style==1 || object.product_style==3 )? ' bgf ':'') + (object.chamfer_of_main_drawing==2 ? ' but_radius5 ':'') }}" style="{{'margin-bottom:'+object.product_spacing+'px;'}}"> |
19 | - <navigator url="{{aitem.goods_type == 1 ? ( nav1 + 'goods_id=' + aitem.goods_id + '&title=' + aitem.goods_name + '&prom_type='+prom_type+'&prom_id=' + aitem.id +'&pre_id=' + aitem.id + '&group_id=' + aitem.id ) : ( nav2 + 'goods_id=' + aitem.goods_id + '&title=' + aitem.goods_name + '&prom_type='+prom_type+'&prom_id=' + aitem.id +'&pre_id=' + aitem.id + '&group_id=' + aitem.id )}}" class="s1_gk_a1"> | |
19 | + <navigator url="{{(prom_type==9 && aitem.residue==0) ? '' : (aitem.goods_type == 1 ? ( nav1 + 'goods_id=' + aitem.goods_id + '&title=' + aitem.goods_name + '&prom_type='+prom_type+'&prom_id=' + aitem.id +'&pre_id=' + aitem.id + '&group_id=' + aitem.id ) : ( nav2 + 'goods_id=' + aitem.goods_id + '&title=' + aitem.goods_name + '&prom_type='+prom_type+'&prom_id=' + aitem.id +'&pre_id=' + aitem.id + '&group_id=' + aitem.id ))}}" class="s1_gk_a1"> | |
20 | 20 | <view class="topBox"> |
21 | 21 | <view class="imgBox"> |
22 | 22 | <!-- <image mode="{{object.picture_fill==1 ? 'aspectFill' : 'scaleToFill'}}" class="{{'new_item1_image '+ 'aspect_ratio'+object.picture_scale}}" style="{{'width:'+img_width+';height:'+img_height}}" src="{{imghost+aitem.original_img}}" data-errorimg="goods_array[{{index}}][{{aind}}].original_img" binderror="bind_bnerr3"></image> --> |
... | ... | @@ -76,7 +76,7 @@ |
76 | 76 | <view style="{{'padding-left:'+object.page_margins+'px;padding-right:'+object.page_margins+'px;'}}" class="{{'flex2 new_item1_box '+ ((object.product_style==1 || object.product_style==3 )? ' bgf ':'') }}"> |
77 | 77 | <block wx:for="{{goods_array}}"> |
78 | 78 | <view wx:for="{{item}}" wx:for-item="aitem" wx:for-index="aind" class="{{'boxpad new_item1 ' + (object.product_style==2 ? ' boxsha ':'') + (object.product_style==3 ? ' aborder ':'') + ((object.product_style==1 || object.product_style==3 )? ' bgf ':'')+ (object.chamfer_of_main_drawing==2 ? ' but_radius5 ':'')}}" style="{{'margin-bottom:'+object.product_spacing+'px; '+('width:calc(100%/2 - ' + object.product_spacing/2+'px)')}}"> |
79 | - <navigator url="{{aitem.goods_type == 1 ? ( nav1 + 'goods_id=' + aitem.goods_id + '&title=' + aitem.goods_name + '&prom_type='+prom_type+'&prom_id=' + aitem.id +'&pre_id=' + aitem.id + '&group_id=' + aitem.id ) : ( nav2 + 'goods_id=' + aitem.goods_id + '&title=' + aitem.goods_name + '&prom_type='+prom_type+'&prom_id=' + aitem.id +'&pre_id=' + aitem.id + '&group_id=' + aitem.id )}}" class="s1_gk_a1"> | |
79 | + <navigator url="{{(prom_type==9 && aitem.residue==0) ? '' : (aitem.goods_type == 1 ? ( nav1 + 'goods_id=' + aitem.goods_id + '&title=' + aitem.goods_name + '&prom_type='+prom_type+'&prom_id=' + aitem.id +'&pre_id=' + aitem.id + '&group_id=' + aitem.id ) : ( nav2 + 'goods_id=' + aitem.goods_id + '&title=' + aitem.goods_name + '&prom_type='+prom_type+'&prom_id=' + aitem.id +'&pre_id=' + aitem.id + '&group_id=' + aitem.id ))}}" class="s1_gk_a1"> | |
80 | 80 | <view class="topBox"> |
81 | 81 | <view class="imgBox"> |
82 | 82 | <!-- <image mode="{{object.picture_fill==1 ? 'aspectFill' : 'scaleToFill'}}" class="{{'new_item1_image '+ 'aspect_ratio'+object.picture_scale}}" style="{{'width:'+img_width+';height:'+img_height}}" src="{{imghost+aitem.original_img}}" data-errorimg="goods_array[{{index}}][{{aind}}].original_img" binderror="bind_bnerr3"></image> --> |
... | ... | @@ -130,7 +130,7 @@ |
130 | 130 | <view style="{{'padding-left:'+object.page_margins+'px;padding-right:'+object.page_margins+'px;'}}" class="{{'flex2 new_item1_box '+ ((object.product_style==1 || object.product_style==3 )? ' bgf ':'')}}"> |
131 | 131 | <block wx:for="{{goods_array}}"> |
132 | 132 | <view wx:for="{{item}}" wx:for-item="aitem" wx:for-index="aind" class="{{'boxpad new_item1 ' + (object.product_style==2 ? ' boxsha ':'') + (object.product_style==3 ? ' aborder ':'') + ((object.product_style==1 || object.product_style==3 )? ' bgf ':'') + (object.chamfer_of_main_drawing==2 ? ' but_radius5 ':'') }}" style="{{'margin-bottom:'+object.product_spacing+'px; '+('width:calc(100%/3 - ' + (object.product_spacing*2)/3+'px)')}}"> |
133 | - <navigator url="{{aitem.goods_type == 1 ? ( nav1 + 'goods_id=' + aitem.goods_id + '&title=' + aitem.goods_name + '&prom_type='+prom_type+'&prom_id=' + aitem.id +'&pre_id=' + aitem.id + '&group_id=' + aitem.id ) : ( nav2 + 'goods_id=' + aitem.goods_id + '&title=' + aitem.goods_name + '&prom_type='+prom_type+'&prom_id=' + aitem.id +'&pre_id=' + aitem.id + '&group_id=' + aitem.id )}}" class="s1_gk_a1"> | |
133 | + <navigator url="{{(prom_type==9 && aitem.residue==0) ? '' : (aitem.goods_type == 1 ? ( nav1 + 'goods_id=' + aitem.goods_id + '&title=' + aitem.goods_name + '&prom_type='+prom_type+'&prom_id=' + aitem.id +'&pre_id=' + aitem.id + '&group_id=' + aitem.id ) : ( nav2 + 'goods_id=' + aitem.goods_id + '&title=' + aitem.goods_name + '&prom_type='+prom_type+'&prom_id=' + aitem.id +'&pre_id=' + aitem.id + '&group_id=' + aitem.id ))}}" class="s1_gk_a1"> | |
134 | 134 | <view class="topBox"> |
135 | 135 | <view class="imgBox"> |
136 | 136 | <!-- <image mode="{{object.picture_fill==1 ? 'aspectFill' : 'scaleToFill'}}" class="{{'new_item1_image '+ 'aspect_ratio'+object.picture_scale}}" style="{{'width:'+img_width+';height:'+img_height}}" src="{{imghost+aitem.original_img}}" data-errorimg="goods_array[{{index}}][{{aind}}].original_img" binderror="bind_bnerr3"></image> --> |
... | ... | @@ -178,7 +178,7 @@ |
178 | 178 | <view style="{{'padding-left:'+object.page_margins+'px;padding-right:'+object.page_margins+'px;'}}" class="{{'flex2 new_item1_box '+ ((object.product_style==1 || object.product_style==3 )? ' bgf ':'') }}"> |
179 | 179 | <block wx:for="{{goods_array}}"> |
180 | 180 | <view wx:for="{{item}}" wx:for-item="aitem" wx:for-index="aind" class="{{'boxpad new_item1 ' + (object.product_style==2 ? ' boxsha ':'') + (object.product_style==3 ? ' aborder ':'') + ((object.product_style==1 || object.product_style==3 )? ' bgf ':'') + (object.chamfer_of_main_drawing==2 ? ' but_radius5 ':'') }}" style="{{'margin-bottom:'+object.product_spacing+'px;'}}"> |
181 | - <navigator style="display: flex;" url="{{aitem.goods_type == 1 ? ( nav1 + 'goods_id=' + aitem.goods_id + '&title=' + aitem.goods_name + '&prom_type='+prom_type+'&prom_id=' + aitem.id +'&pre_id=' + aitem.id + '&group_id=' + aitem.id ) : ( nav2 + 'goods_id=' + aitem.goods_id + '&title=' + aitem.goods_name + '&prom_type='+prom_type+'&prom_id=' + aitem.id +'&pre_id=' + aitem.id + '&group_id=' + aitem.id )}}" class="s1_gk_a1"> | |
181 | + <navigator style="display: flex;" url="{{(prom_type==9 && aitem.residue==0) ? '' : (aitem.goods_type == 1 ? ( nav1 + 'goods_id=' + aitem.goods_id + '&title=' + aitem.goods_name + '&prom_type='+prom_type+'&prom_id=' + aitem.id +'&pre_id=' + aitem.id + '&group_id=' + aitem.id ) : ( nav2 + 'goods_id=' + aitem.goods_id + '&title=' + aitem.goods_name + '&prom_type='+prom_type+'&prom_id=' + aitem.id +'&pre_id=' + aitem.id + '&group_id=' + aitem.id ))}}" class="s1_gk_a1"> | |
182 | 182 | <view style="width: 33%;" class="topBox"> |
183 | 183 | <view class="imgBox"> |
184 | 184 | <view class="{{'container'+object.picture_scale}}" style="{{object.picture_fill==1 ? 'background-color: #fff;' : ''}}"> |
... | ... | @@ -231,7 +231,7 @@ |
231 | 231 | <block wx:for="{{goods_array}}"> |
232 | 232 | <block wx:for="{{item}}" wx:for-item="aitem" wx:for-index="aind"> |
233 | 233 | <view wx:if="{{aind==0}}" class="{{'new_item1 ' + (object.product_style==2 ? ' boxsha ':'') + (object.product_style==3 ? ' aborder ':'') + (object.chamfer_of_main_drawing==2 ? ' but_radius5 ':'') + ((object.product_style==1 || object.product_style==3 )? ' bgf ':'')}}" style="{{'margin-bottom:'+object.product_spacing+'px;'}}"> |
234 | - <navigator url="{{aitem.goods_type == 1 ? ( nav1 + 'goods_id=' + aitem.goods_id + '&title=' + aitem.goods_name + '&prom_type=' + prom_type + '&prom_id=' + aitem.id +'&pre_id=' + aitem.id + '&group_id=' + aitem.id ) : ( nav2 + 'goods_id=' + aitem.goods_id + '&title=' + aitem.goods_name + '&prom_type='+ prom_type +'&prom_id=' + aitem.id +'&pre_id=' + aitem.id + '&group_id=' + aitem.id )}}" class="s1_gk_a1"> | |
234 | + <navigator url="{{(prom_type==9 && aitem.residue==0) ? '' : (aitem.goods_type == 1 ? ( nav1 + 'goods_id=' + aitem.goods_id + '&title=' + aitem.goods_name + '&prom_type=' + prom_type + '&prom_id=' + aitem.id +'&pre_id=' + aitem.id + '&group_id=' + aitem.id ) : ( nav2 + 'goods_id=' + aitem.goods_id + '&title=' + aitem.goods_name + '&prom_type='+ prom_type +'&prom_id=' + aitem.id +'&pre_id=' + aitem.id + '&group_id=' + aitem.id ))}}" class="s1_gk_a1"> | |
235 | 235 | <view class="topBox"> |
236 | 236 | <view class="imgBox"> |
237 | 237 | <view class="{{'container'+object.picture_scale}}" style="{{object.picture_fill==1 ? 'background-color: #fff;' : ''}}"> |
... | ... | @@ -281,7 +281,7 @@ |
281 | 281 | </navigator> |
282 | 282 | </view> |
283 | 283 | <view wx:if="{{aind==1}}" class="{{'boxpad new_item1 ' + (object.product_style==2 ? ' boxsha ':'') + (object.product_style==3 ? ' aborder ':'') + ((object.product_style==1 || object.product_style==3 )? ' bgf ':'') + (object.chamfer_of_main_drawing==2 ? ' but_radius5 ':'')}}" style="{{'margin-bottom:'+object.product_spacing+'px; '+('width:calc(100%/2 - ' + object.product_spacing/2+'px)')}}"> |
284 | - <navigator url="{{aitem.goods_type == 1 ? ( nav1 + 'goods_id=' + aitem.goods_id + '&title=' + aitem.goods_name + '&prom_type=' + prom_type + '&prom_id=' + aitem.id +'&pre_id=' + aitem.id + '&group_id=' + aitem.id ) : ( nav2 + 'goods_id=' + aitem.goods_id + '&title=' + aitem.goods_name + '&prom_type='+ prom_type +'&prom_id=' + aitem.id +'&pre_id=' + aitem.id + '&group_id=' + aitem.id )}}" class="s1_gk_a1"> | |
284 | + <navigator url="{{(prom_type==9 && aitem.residue==0) ? '' : (aitem.goods_type == 1 ? ( nav1 + 'goods_id=' + aitem.goods_id + '&title=' + aitem.goods_name + '&prom_type=' + prom_type + '&prom_id=' + aitem.id +'&pre_id=' + aitem.id + '&group_id=' + aitem.id ) : ( nav2 + 'goods_id=' + aitem.goods_id + '&title=' + aitem.goods_name + '&prom_type='+ prom_type +'&prom_id=' + aitem.id +'&pre_id=' + aitem.id + '&group_id=' + aitem.id ))}}" class="s1_gk_a1"> | |
285 | 285 | <view class="topBox"> |
286 | 286 | <view class="imgBox"> |
287 | 287 | <view class="{{'container'+object.picture_scale}}" style="{{object.picture_fill==1 ? 'background-color: #fff;' : ''}}"> |
... | ... | @@ -323,7 +323,7 @@ |
323 | 323 | </navigator> |
324 | 324 | </view> |
325 | 325 | <view wx:if="{{aind==2}}" class="{{'boxpad new_item1 ' + (object.product_style==2 ? ' boxsha ':'') + (object.product_style==3 ? ' aborder ':'') + ((object.product_style==1 || object.product_style==3 )? ' bgf ':'') + (object.chamfer_of_main_drawing==2 ? ' but_radius5 ':'') }}" style="{{'margin-bottom:'+object.product_spacing+'px; '+('width:calc(100%/2 - ' + object.product_spacing/2+'px)')}}"> |
326 | - <navigator url="{{aitem.goods_type == 1 ? ( nav1 + 'goods_id=' + aitem.goods_id + '&title=' + aitem.goods_name + '&prom_type=' + prom_type + '&prom_id=' + aitem.id +'&pre_id=' + aitem.id + '&group_id=' + aitem.id ) : ( nav2 + 'goods_id=' + aitem.goods_id + '&title=' + aitem.goods_name + '&prom_type='+ prom_type +'&prom_id=' + aitem.id +'&pre_id=' + aitem.id + '&group_id=' + aitem.id )}}" class="s1_gk_a1"> | |
326 | + <navigator url="{{(prom_type==9 && aitem.residue==0) ? '' : (aitem.goods_type == 1 ? ( nav1 + 'goods_id=' + aitem.goods_id + '&title=' + aitem.goods_name + '&prom_type=' + prom_type + '&prom_id=' + aitem.id +'&pre_id=' + aitem.id + '&group_id=' + aitem.id ) : ( nav2 + 'goods_id=' + aitem.goods_id + '&title=' + aitem.goods_name + '&prom_type='+ prom_type +'&prom_id=' + aitem.id +'&pre_id=' + aitem.id + '&group_id=' + aitem.id ))}}" class="s1_gk_a1"> | |
327 | 327 | <view class="topBox"> |
328 | 328 | <view class="imgBox"> |
329 | 329 | <view class="{{'container'+object.picture_scale}}" style="{{object.picture_fill==1 ? 'background-color: #fff;' : ''}}"> |
... | ... | @@ -422,7 +422,7 @@ |
422 | 422 | <swiper indicator-dots style="{{'padding-left:'+object.page_margins+'px;padding-right:'+object.page_margins+'px;'+(swiperHeight ? ('height:'+swiperHeight+';'):'' )}}" class="{{' new_item1_box '+ ((object.product_style==1 || object.product_style==3 )? ' bgf ':'')}}"> |
423 | 423 | <swiper-item wx:for="{{goods_array}}" class="flex2" style="padding: 5rpx;"> |
424 | 424 | <view wx:for="{{item}}" wx:for-item="aitem" wx:for-index="aind" class="{{'boxpad swiper_h new_item1 ' + (object.product_style==2 ? ' boxsha ':'') + (object.product_style==3 ? ' aborder ':'') + ((object.product_style==1 || object.product_style==3 )? ' bgf ':'') + (object.chamfer_of_main_drawing==2 ? ' but_radius5 ':'') }}" style="{{'margin-bottom:'+object.product_spacing+'px; '+('width:calc(100%/3 - ' + (object.product_spacing*2)/3+'px)')}}"> |
425 | - <navigator url="{{aitem.goods_type == 1 ? ( nav1 + 'goods_id=' + aitem.goods_id + '&title=' + aitem.goods_name + '&prom_type=' + prom_type + '&prom_id=' + aitem.id +'&pre_id=' + aitem.id + '&group_id=' + aitem.id ) : ( nav2 + 'goods_id=' + aitem.goods_id + '&title=' + aitem.goods_name + '&prom_type='+ prom_type +'&prom_id=' + aitem.id +'&pre_id=' + aitem.id + '&group_id=' + aitem.id )}}" class="s1_gk_a1"> | |
425 | + <navigator url="{{(prom_type==9 && aitem.residue==0) ? '' : (aitem.goods_type == 1 ? ( nav1 + 'goods_id=' + aitem.goods_id + '&title=' + aitem.goods_name + '&prom_type=' + prom_type + '&prom_id=' + aitem.id +'&pre_id=' + aitem.id + '&group_id=' + aitem.id ) : ( nav2 + 'goods_id=' + aitem.goods_id + '&title=' + aitem.goods_name + '&prom_type='+ prom_type +'&prom_id=' + aitem.id +'&pre_id=' + aitem.id + '&group_id=' + aitem.id ))}}" class="s1_gk_a1"> | |
426 | 426 | <view class="topBox"> |
427 | 427 | <view class="imgBox"> |
428 | 428 | <view class="{{'container'+object.picture_scale}}" style="{{object.picture_fill==1 ? 'background-color: #fff;' : ''}}"> | ... | ... |
components/diy_public/diy_public.wxss
... | ... | @@ -555,4 +555,14 @@ swiper { |
555 | 555 | border-radius: 10rpx; |
556 | 556 | margin-right: 10rpx; |
557 | 557 | opacity: .8; |
558 | + } | |
559 | + .lucky{ | |
560 | + display: inline-block; | |
561 | + font-size: 24rpx; | |
562 | + padding: 0 10rpx; | |
563 | + background-color: #f23023; | |
564 | + opacity: .8; | |
565 | + color: #fff; | |
566 | + margin-right: 10rpx; | |
567 | + border-radius: 10rpx; | |
558 | 568 | } |
559 | 569 | \ No newline at end of file | ... | ... |
pages/index/index/index.wxml
... | ... | @@ -484,9 +484,12 @@ |
484 | 484 | <diy_public object="{{item.content}}" prom_type="6"></diy_public> |
485 | 485 | </block> |
486 | 486 | <!--秒杀--> |
487 | - <block wx:if="{{item.ename=='seckill' || item.ename=='seckillNew'}}"> | |
487 | + <block wx:if="{{item.ename=='seckill'}}"> | |
488 | 488 | <seckill object="{{item.content}}"></seckill> |
489 | 489 | </block> |
490 | + <block wx:if="{{item.ename=='seckillNew'}}"> | |
491 | + <diy_public object="{{item.content}}" prom_type="1"></diy_public> | |
492 | + </block> | |
490 | 493 | <!--标题--> |
491 | 494 | <block wx:if="{{item.ename=='title'}}"> |
492 | 495 | <title object="{{item.content}}"></title> |
... | ... | @@ -530,6 +533,10 @@ |
530 | 533 | <block wx:if="{{item.ename=='luckyactivity'}}"> |
531 | 534 | <luckyGo object="{{item.content}}"></luckyGo> |
532 | 535 | </block> |
536 | + <block wx:if="{{item.ename=='luckyactivityNew'}}"> | |
537 | + <!-- <luckyGo object="{{item.content}}"></luckyGo> --> | |
538 | + <diy_public object="{{item.content}}" prom_type="9"></diy_public> | |
539 | + </block> | |
533 | 540 | |
534 | 541 | <!-- 服务卡项 --> |
535 | 542 | <block wx:if="{{item.ename=='servicecategory'}}"> | ... | ... |
pages/template/index.json
... | ... | @@ -11,6 +11,7 @@ |
11 | 11 | "searchbox":"/components/diy_searchbox/diy_searchbox", |
12 | 12 | "shopname": "/components/diy_shopname/diy_shopname", |
13 | 13 | "pingd_buy": "/components/diy_pingd_buy/diy_pingd_buy", |
14 | + "luckyGo": "/components/diy_luckyGo/diy_luckyGo", | |
14 | 15 | "diy_public": "/components/diy_public/diy_public", |
15 | 16 | "title": "/components/diy_title/diy_title", |
16 | 17 | "notice": "/components/diy_notice/diy_notice", | ... | ... |
pages/template/index.wxml
... | ... | @@ -41,9 +41,12 @@ |
41 | 41 | <diy_public object="{{item.content}}" prom_type="6"></diy_public> |
42 | 42 | </block> |
43 | 43 | <!--秒杀--> |
44 | - <block wx:if="{{item.ename=='seckill' || item.ename=='seckillNew'}}"> | |
44 | + <block wx:if="{{item.ename=='seckill'}}"> | |
45 | 45 | <seckill object="{{item.content}}"></seckill> |
46 | 46 | </block> |
47 | + <block wx:if="{{item.ename=='seckillNew'}}"> | |
48 | + <diy_public object="{{item.content}}" prom_type="1"></diy_public> | |
49 | + </block> | |
47 | 50 | <!--标题--> |
48 | 51 | <block wx:if="{{item.ename=='title'}}"> |
49 | 52 | <title object="{{item.content}}"></title> |
... | ... | @@ -79,6 +82,15 @@ |
79 | 82 | <block wx:if="{{item.ename=='groupbuyNew'}}"> |
80 | 83 | <diy_public object="{{item.content}}" prom_type="2"></diy_public> |
81 | 84 | </block> |
85 | + | |
86 | + <!-- 幸运购 --> | |
87 | + <block wx:if="{{item.ename=='luckyactivity'}}"> | |
88 | + <luckyGo object="{{item.content}}"></luckyGo> | |
89 | + </block> | |
90 | + <block wx:if="{{item.ename=='luckyactivityNew'}}"> | |
91 | + <!-- <luckyGo object="{{item.content}}"></luckyGo> --> | |
92 | + <diy_public object="{{item.content}}" prom_type="9"></diy_public> | |
93 | + </block> | |
82 | 94 | </view> |
83 | 95 | </block> |
84 | 96 | </view> | ... | ... |