Commit 90ab03dab66605773406ab610b04b4a63935eb95

Authored by 前端开发-罗建龙
1 parent 08c0e65f

oa优化

pages/user/user_spsy/user_spsy.js
... ... @@ -15,7 +15,8 @@ Page({
15 15 page: 1,
16 16 isLoading: 0,
17 17 no_more: 0,
18   - is_use: 0 //领取状态
  18 + is_use: 0, //领取状态
  19 + is_appoint_storage:0 //是否要登记门店才可以领取 0是不用,1要登记
19 20 },
20 21 /**
21 22 * 生命周期函数--监听页面加载
... ... @@ -41,6 +42,14 @@ Page({
41 42 * 生命周期函数--监听页面显示
42 43 */
43 44 onShow: function () {
  45 + let th=this
  46 + //先获取是否有关闭使用优惠券
  47 + getApp().getConfig2(function (ee) {
  48 + var json_d = JSON.parse(ee.switch_list);
  49 + th.setData({
  50 + is_appoint_storage:json_d.is_appoint_storage,//是否要登记门店才可以领取 0是不用,1要登记
  51 + });
  52 + }, 1);
44 53 getApp().check_can_share();
45 54 },
46 55 async getQrCode(FormId,GradeId) {
... ...
pages/user/user_spsy/user_spsy.wxml
... ... @@ -14,7 +14,7 @@
14 14 </view> -->
15 15 <view wx:if="{{is_use}}" class="btn1">已使用</view>
16 16 <block wx:else>
17   - <view wx:if="{{qr_code_object.StorageID}}" bindtap="show_hxm" data-type="1" class="btn">立即使用</view>
  17 + <view wx:if="{{!is_appoint_storage || qr_code_object.StorageID}}" bindtap="show_hxm" data-type="1" class="btn">立即使用</view>
18 18 <view wx:else bindtap="select_product" data-type="1" class="btn">登记取货</view>
19 19 </block>
20 20 <!-- <view bindtap="right_use" class="btn">立即使用</view></view> -->
... ...