Commit 734565da6e15f6495da3b354952bfbd332d53506
1 parent
98b1710b
检查授权登陆
Showing
2 changed files
with
22 additions
and
47 deletions
packageC/pages/luckyGo/luckyGo_goodsInfo/luckyGo_goodsInfo.js
... | ... | @@ -315,54 +315,8 @@ Page({ |
315 | 315 | prom_id, |
316 | 316 | }); |
317 | 317 | } |
318 | + | |
318 | 319 | |
319 | - | |
320 | - | |
321 | - // api/weshop/prom/luckyOrder/getUserOrderInfo/{store_id}/{user_id}/{aid} | |
322 | - // getApp().request.promiseGet("/api/weshop/pickup/list", { | |
323 | - // data: { store_id: os.stoid, pickup_id: e.pickup_id, lat: th.data.lat, lon: th.data.lon,is_pos:1 }, | |
324 | - // }).then(res => { | |
325 | - // if (res.data.code == 0) { | |
326 | - // e = res.data.data.pageData[0]; | |
327 | - // if (e) { | |
328 | - // e.is_no_dis = ee.is_no_dis; | |
329 | - // appd.pk_store = e; | |
330 | - // that.set_def_storage(e); | |
331 | - // } | |
332 | - | |
333 | - // } | |
334 | - // }) | |
335 | - | |
336 | - | |
337 | - // console.log('type********>>',this.data.prom_type); | |
338 | - //-- 自定义海报 -- | |
339 | - // getApp().request.promiseGet("/api/weshop/goods/poster/page", { | |
340 | - // data: { store_id: os.stoid, type: 1, is_use: 1 } | |
341 | - // }).then(res => { | |
342 | - // if (res.data.code == 0 && res.data.data && res.data.data.pageData && res.data.data.pageData[0]) { | |
343 | - | |
344 | - // var poster_data = res.data.data.pageData[0]; | |
345 | - // var json_str = poster_data.jsonStr; | |
346 | - | |
347 | - // if (json_str) { | |
348 | - // var json_data = JSON.parse(json_str); | |
349 | - // if (json_data.bg_img) { | |
350 | - | |
351 | - // //-- 把图片那到本地 -- | |
352 | - // wx.getImageInfo({ | |
353 | - // src: json_data.bg_img, | |
354 | - // success: function (res) { | |
355 | - // var path = res.path; | |
356 | - // th.setData({ share_b_img: path }) | |
357 | - // }, | |
358 | - // fail: function (res) { } | |
359 | - // }); | |
360 | - // } | |
361 | - // th.setData({ poster: json_data }) | |
362 | - | |
363 | - // } | |
364 | - // } | |
365 | - // }) | |
366 | 320 | |
367 | 321 | |
368 | 322 | //---获取手机地址坐标-- |
... | ... | @@ -570,6 +524,16 @@ Page({ |
570 | 524 | getApp().request.put("/api/weshop/goods/updateClick", { |
571 | 525 | data: { store_id: os.stoid, goods_id: gid } |
572 | 526 | }); |
527 | + | |
528 | + | |
529 | + //--先判断会员登陆状态-- | |
530 | + var user_info = getApp().globalData.userInfo; | |
531 | + if (user_info == null || user_info.mobile == undefined || user_info.mobile == "" || user_info.mobile == null) { | |
532 | + that.setData({ | |
533 | + noLogin: true | |
534 | + }) | |
535 | + return false; | |
536 | + } | |
573 | 537 | |
574 | 538 | }, |
575 | 539 | |
... | ... | @@ -3920,6 +3884,16 @@ Page({ |
3920 | 3884 | // ind == 1 为普通购买 |
3921 | 3885 | openSpecModel_pt: function (e) { |
3922 | 3886 | |
3887 | + //--先判断会员登陆状态-- | |
3888 | + var user_info = getApp().globalData.userInfo; | |
3889 | + if (user_info == null || user_info.mobile == undefined || user_info.mobile == "" || user_info.mobile == null) { | |
3890 | + wx.navigateTo({ | |
3891 | + url: '/pages/togoin/togoin', | |
3892 | + }) | |
3893 | + return false; | |
3894 | + } | |
3895 | + | |
3896 | + | |
3923 | 3897 | this.setData({ open_ind_store: 9, goodsInputNum: 1 }); |
3924 | 3898 | // 判断是否有待支付订单 |
3925 | 3899 | var aid = this.data.group_id; | ... | ... |
packageC/pages/luckyGo/luckyGo_goodsInfo/luckyGo_goodsInfo.wxml
... | ... | @@ -921,6 +921,7 @@ |
921 | 921 | <!-- data-ind="2" --> |
922 | 922 | <!-- openSpecModel_pt --> |
923 | 923 | <view class="xc-ash-b f1 flex ai-center jc-center white fs26" wx:if="{{isTimeUp}}">活动已经结束</view> |
924 | + <view wx:elif="{{noLogin}}" bindtap="openSpecModel_pt">立即参团</view> | |
924 | 925 | <block wx:else> |
925 | 926 | <view class="btn-red f1 flex ai-center jc-center" bindtap="go" data-it="0" data-url="/packageC/pages/luckyGo/luckyGo_details/luckyGo_details?group_id={{luckGoInfo.id}}&goods_id={{luckGoInfo.goods_id}}&goods_name={{data.goods_name}}&team_id={{buyInfo.team_id}}" wx:if="{{showDetails}}">查看详情</view> |
926 | 927 | <view class="btn-red f1 flex ai-center jc-center" bindtap="openSpecModel_pt" data-it="0" wx:elif="{{!showDetails && surplus != 0 && canBuy}}">立即参团</view> | ... | ... |