| @@ -1,10 +1,10 @@ | |||
| var extConfig = wx.getExtConfigSync ? wx.getExtConfigSync() : {}; | |||
| var appId = extConfig.appId; | |||
| var config = { | |||
| url: "https://ciformall.youlane.cn/C/api", | |||
| // url: "https://ciformall.youlane.cn/C/api", | |||
| // url:"https://c.malls.iformall.com/C/api", | |||
| // url:'https://ctest.malls.iformall.com/C/api', | |||
| // url:'http://10.100.33.68:7000/C/api', | |||
| url:'http://10.100.33.69:7000/C/api', | |||
| // url: 'http://202.165.179.86:4000/C/api', | |||
| api: { | |||
| /** | |||
| @@ -127,7 +127,7 @@ Page({ | |||
| console.log(tmpArr) | |||
| let lists = []; | |||
| tmpArr.map(file => { | |||
| if (file.orderStatus != 0) { | |||
| if (file.orderStatus != 1) { | |||
| lists.push(file); | |||
| } | |||
| }) | |||
| @@ -135,8 +135,10 @@ Page({ | |||
| lists: lists | |||
| }) | |||
| } | |||
| wx.stopPullDownRefresh(); | |||
| }) | |||
| .catch(err => { | |||
| wx.stopPullDownRefresh(); | |||
| wx.showToast({ | |||
| title: err.message, | |||
| icon: 'none', | |||
| @@ -5,7 +5,7 @@ | |||
| </view> | |||
| <view class="list" hover-class="none" hover-stop-propagation="false"> | |||
| <view class="listitem clearfix" wx:for="{{lists}}" wx:key="{{index}}" hover-stop-propagation="false" data-couponId='{{item.couponId}}' data-id='{{item.id}}' bindtap='invite'> | |||
| <image class="fl" src="{{item.coverImg}}" mode="widthFix" lazy-load="true" binderror="" | |||
| <image class="fl" src="{{item.coverImg}}" mode="aspectFill" lazy-load="true" binderror="" | |||
| bindload=""></image> | |||
| <view class="fl ri" hover-class="none" hover-stop-propagation="false"> | |||
| <text class="txt01">{{item.title}}</text> | |||
| @@ -15,13 +15,13 @@ | |||
| </view> | |||
| <view class="botton" hover-class="none" hover-stop-propagation="false">发起砍价</view> | |||
| </view> | |||
| <view class="loading" wx:if="{{loading}}"><image src="{{loadingUrl}}" mode="widthFix"></image>{{content}}</view> | |||
| <view class="loading" wx:if="{{loading}}"><image src="{{loadingUrl}}" mode="aspectFill"></image>{{content}}</view> | |||
| <!-- <view class='loadingtext' wx:if="{{loadingtext}}">{{loadingtext}}</view> --> | |||
| </view> | |||
| </view> | |||
| <view class="list mybargain" wx:if="{{mybargain}}" hover-class="none" hover-stop-propagation="false"> | |||
| <view class="listitem clearfix" wx:for="{{lists}}" wx:key="index" hover-stop-propagation="false"> | |||
| <image class="fl" src="{{item.coverImg}}" mode="widthFix" lazy-load="true"></image> | |||
| <image class="fl" src="{{item.coverImg}}" mode="aspectFill" lazy-load="true"></image> | |||
| <view class="fl ri" hover-class="none" hover-stop-propagation="false"> | |||
| <text class="txt01">{{item.title}}</text> | |||
| <text class="txt02">{{item.subTitle}}</text> | |||
| @@ -36,11 +36,7 @@ | |||
| <view class="botton2" hover-class="none" hover-stop-propagation="false">立即支付</view> | |||
| <image class="icon" src="./../../assets/images/bargainsuccess.png" lazy-load="true"/> | |||
| </view> | |||
| <view class='again' wx:if="{{item.orderStatus == 1}}" data-id="{{item.id}}" bindtap="inviteFriend"> | |||
| <!-- <view class="botton2" hover-class="none" hover-stop-propagation="false">立即支付</view> --> | |||
| <image class="icon" style='margin-top:60rpx;' src="./../../assets/images/bargainsuccess.png" lazy-load="true"/> | |||
| </view> | |||
| <view class='again' wx:if="{{item.orderStatus == 8||item.orderStatus == 6&&todayDate>item.pressEndDate}}" data-couponChannelId="{{item.couponChannelId}}" data-couponId="{{item.productId}}" data-id="{{item.id}}" bindtap="barginAgain"> | |||
| <view class='again' wx:if="{{item.orderStatus == 8||item.orderStatus == 6&&todayDate>item.pressEndDate}}" data-couponChannelId="{{item.couponChannelId}}" data-couponId="{{item.productId}}" data-id="{{item.id}}" bindtap="barginAgain"> | |||
| <view class="botton3" hover-class="none" hover-stop-propagation="false">重新砍价</view> | |||
| <image class="icon" src="./../../assets/images/bargainfail.png" lazy-load="true"/> | |||
| </view> | |||
| @@ -49,7 +45,7 @@ | |||
| <image class="icon" style="margin-top:60rpx;" src="./../../assets/images/bargaincancel.png" lazy-load="true"/> | |||
| </view> | |||
| </view> | |||
| <view class="loading" wx:if="{{loading}}"><image src="{{loadingUrl}}" mode="widthFix"></image>{{content}}</view> | |||
| <view class="loading" wx:if="{{loading}}"><image src="{{loadingUrl}}" mode="aspectFill"></image>{{content}}</view> | |||
| <!-- <view class='loadingtext' wx:if="{{loadingtext}}">{{loadingtext}}</view> --> | |||
| </view> | |||
| <view class='dingdan' wx:if="{{lists.length==0}}"> | |||
| @@ -18,7 +18,8 @@ Page({ | |||
| showPage: false, | |||
| discountStatus:null, | |||
| disabled:false, | |||
| display:"block!important" | |||
| display:"block!important", | |||
| showButton: false | |||
| }, | |||
| /** | |||
| @@ -47,6 +48,7 @@ Page({ | |||
| var todayDate = new Date().getTime(); | |||
| that.setData({ | |||
| todayDate: todayDate, | |||
| showButton:false | |||
| }) | |||
| }, | |||
| /** | |||
| @@ -69,6 +71,8 @@ Page({ | |||
| } | |||
| }) | |||
| .then(res => { | |||
| console.log(res) | |||
| console.log("--------------------------------status------------------------------------------") | |||
| if (res.data.status == 1) { | |||
| that.setData({ | |||
| discountStatus: 1 | |||
| @@ -135,6 +139,10 @@ Page({ | |||
| file.createDate = diffTime(file.createDate) | |||
| }) | |||
| that.countdown(res.data.pressEndDate); | |||
| res.data.orderPressList.map(file=>{ | |||
| compare(file.first); | |||
| }) | |||
| console.log(res.data.orderPressList.sort(compare('first'))) | |||
| that.setData({ | |||
| data: res.data, | |||
| already: (res.data.price / 100 - res.data.salePrice / 100 - res.data.pressCurrentValue / 100).toFixed(2), | |||
| @@ -251,12 +259,17 @@ Page({ | |||
| */ | |||
| orderFunc(e) { | |||
| var that = this; | |||
| console.log(e) | |||
| that.setData({ | |||
| showButton:true | |||
| }) | |||
| Http.post({ | |||
| url: config.api.checkPhoneStatus, | |||
| data: {} | |||
| }) | |||
| .then(res => { | |||
| that.setData({ | |||
| showButton: false | |||
| }) | |||
| if (typeof(res) != "undefined") { | |||
| let orderId = "" + e.currentTarget.dataset.orderid; | |||
| that.setData({ | |||
| @@ -350,6 +363,9 @@ Page({ | |||
| } | |||
| }) | |||
| .catch(err => { | |||
| that.setData({ | |||
| showButton: true | |||
| }) | |||
| if (err.code == 2011) { | |||
| wx.showToast({ | |||
| title: "商户信息没找到", | |||
| @@ -373,7 +389,7 @@ Page({ | |||
| }); | |||
| } else if (err.code == 3001) { | |||
| wx.showToast({ | |||
| title: "领取达到上限", | |||
| title: "超过限购条件", | |||
| image: './../../../assets/images/fail.png', | |||
| duration: 2000, | |||
| mask: false | |||
| @@ -440,6 +456,7 @@ Page({ | |||
| * @param {朋友邀请砍价} e | |||
| */ | |||
| barginAgain: function(e) { | |||
| let that = this; | |||
| let couponChannelId = e.currentTarget.dataset.couponchannelid; | |||
| let couponId = e.currentTarget.dataset.couponid; | |||
| wx.navigateTo({ | |||
| @@ -515,4 +532,11 @@ function diffTime(startDate) { | |||
| }else{ | |||
| return '1秒' | |||
| } | |||
| } | |||
| } | |||
| function compare(property) { | |||
| return function (a, b) { | |||
| var value1 = a[property]; | |||
| var value2 = b[property]; | |||
| return value2 - value1; | |||
| } | |||
| } | |||
| @@ -1,7 +1,6 @@ | |||
| <view class="bargainDetail" hover-class="none" hover-stop-propagation="false" wx:if="{{showPage}}"> | |||
| <view class="listitem clearfix" hover-class="none" hover-stop-propagation="false"> | |||
| <image class="fl" src="{{data.coverImg}}" lazy-load="true" binderror="" | |||
| bindload=""></image> | |||
| <image class="fl" src="{{data.coverImg}}" lazy-load="true" binderror="" bindload="" mode='aspectFill'></image> | |||
| <view class="fl ri" hover-class="none" hover-stop-propagation="false"> | |||
| <text class="txt01">{{data.title}}</text> | |||
| <text class="txt02">{{data.subTitle}}</text> | |||
| @@ -19,7 +18,7 @@ | |||
| 还剩 <text>{{hour}}</text>:<text>{{min}}</text>:<text>{{sec}}</text> 结束 | |||
| </view> | |||
| </view> | |||
| <view class="fail" hover-class="none" hover-stop-propagation="false" wx:if="{{todayDate>data.pressEndDate && from=='discount'&& discountStatus !=1}}"> | |||
| <view class="fail" hover-class="none" hover-stop-propagation="false" wx:if="{{todayDate>data.pressEndDate && discountStatus !=1}}"> | |||
| 好友的砍价已过期 | |||
| </view> | |||
| <view class="fail" hover-class="none" hover-stop-propagation="false" wx:if="{{todayDate>data.pressEndDate && discountStatus ==1}}"> | |||
| @@ -29,24 +28,29 @@ | |||
| <button bindtap="barginAgain" data-couponChannelId="{{data.couponChannelId}}" data-couponId="{{data.productId}}" data-id="{{data.id}}">发起砍价</button> | |||
| <button bindtap="gotomore">更多砍价商品</button> | |||
| </view> | |||
| <view class='help' wx:if="{{(data.pressLimitNum-data.orderPressList.length)!=0&&data.orderStatus != 7||(data.pressLimitNum-data.orderPressList.length)!=0&&data.orderStatus != 1}}">还需邀请<text>{{data.pressLimitNum-data.orderPressList.length}}</text>位好友,帮忙砍至底价</view> | |||
| <view class="success" wx:if="{{data.orderStatus == 7||data.orderStatus == 1}}" hover-class="none" hover-stop-propagation="false"> | |||
| <image src="./../../../assets/images/success01.png" mode="widthFix"></image> | |||
| <text class="" selectable="false" space="false" decode="false"> | |||
| 砍价成功 | |||
| 已砍至底价 | |||
| </text> | |||
| </view> | |||
| <view wx:if="{{data.orderStatus == 6&&discountStatus == 2}}"> | |||
| <button bindtap='helpDiscount' class='helpDiscount'>帮好友砍价</button> | |||
| <view class='helpDiscount' wx:if="{{data.orderStatus == 6&&discountStatus == 2}}"> | |||
| <!-- <button bindtap='helpDiscount' class='helpDiscount'>帮好友砍价</button> --> | |||
| <image bindtap='helpDiscount' src='./../../../assets/images/help.gif' mode='widthFix'></image> | |||
| </view> | |||
| <view class="people" hover-class="none" hover-stop-propagation="false"> | |||
| <view class='title'> | |||
| 砍价人数{{data.orderPressList.length}}/{{data.pressLimitNum}}人 | |||
| </view> | |||
| <view class="clearfix person" wx:for="{{data.orderPressList}}" wx:key="index"> | |||
| <view class="head fl"> | |||
| <image class="headicon" src="{{item.avatarUrl}}" mode="widthFix" lazy-load="true" binderror="" bindload="" /> | |||
| <text wx:if="{{item.first==1}}">发起人</text> | |||
| </view> | |||
| <view class="text fl clearfix"> | |||
| <text class="text01 fl"><text>{{item.nickName}}</text>砍价成功!</text> | |||
| <text class="text01 fl"><text>{{item.nickName}}</text></text> | |||
| <text class="text02 fl"><text class="fl">砍掉</text><text class="fl">{{item.pressValue/100}}元</text></text> | |||
| <text class="text03 fr">{{item.createDate}}前</text> | |||
| </view> | |||
| @@ -54,10 +58,10 @@ | |||
| </view> | |||
| <view wx:if="{{data.orderStatus != 7&&discountStatus==1&&todayDate<=data.pressEndDate&&data.orderStatus!=1}}" class="btns clearfix" hover-class="none" hover-stop-propagation="false"> | |||
| <view class="fl" bindtap='orderFunc' data-orderId="{{data.id}}" data-price="{{data.price/100}}"> | |||
| <button class="fl" bindtap='orderFunc' disabled='{{showButton}}' data-orderId="{{data.id}}" data-price="{{data.price/100}}"> | |||
| <text>{{data.price/100}}元</text> | |||
| <text>立即购买</text> | |||
| </view> | |||
| </button> | |||
| <button class='share user-motto fr' data-orderId='{{data.id}}' id="shareBtn" open-type="share" hover-class="other-button-hover">邀请好友继续砍价</button> | |||
| </view> | |||
| <view style='display:{{display}}' wx:if="{{data.orderStatus == 7&&discountStatus == 1}}" class="btns01 clearfix" hover-class="none" hover-stop-propagation="false"> | |||
| @@ -15,7 +15,26 @@ | |||
| top: 12rpx; | |||
| right: 0; | |||
| } | |||
| .title{ | |||
| display: block; | |||
| font-size: 30rpx; | |||
| color: #333; | |||
| height: 40rpx; | |||
| line-height: 40rpx; | |||
| padding-top: 20rpx; | |||
| } | |||
| .help{ | |||
| display: block; | |||
| text-align: center; | |||
| font-size: 28rpx; | |||
| height: 40rpx; | |||
| line-height: 40rpx; | |||
| margin-top: 47rpx; | |||
| margin-bottom: 40rpx; | |||
| } | |||
| .help text{ | |||
| color: red; | |||
| } | |||
| .listitem .ri { | |||
| margin-left: 26rpx; | |||
| width: 305rpx; | |||
| @@ -109,6 +128,7 @@ | |||
| line-height: 40rpx; | |||
| background: rgba(51, 51, 51, 1); | |||
| border-radius: 10rpx; | |||
| margin: 0 4px; | |||
| } | |||
| .head{ | |||
| width:10%; | |||
| @@ -140,9 +160,11 @@ | |||
| font-size: 26rpx; | |||
| } | |||
| .text01{ | |||
| width: 220rpx; | |||
| width: 100rpx; | |||
| margin-right: 6rpx; | |||
| overflow: hidden; | |||
| height: 76rpx; | |||
| line-height: 76rpx; | |||
| } | |||
| .text01 text{ | |||
| width: 100rpx; | |||
| @@ -155,14 +177,16 @@ | |||
| } | |||
| .text02{ | |||
| display: inline-block; | |||
| width: 140rpx; | |||
| width: 220rpx; | |||
| overflow: hidden; | |||
| } | |||
| .text03{ | |||
| width: 212rpx; | |||
| overflow: hidden; | |||
| width: 240rpx; | |||
| text-align: right; | |||
| font-size:24rpx; | |||
| height: 76rpx; | |||
| line-height: 76rpx; | |||
| overflow: hidden; | |||
| } | |||
| .person{ | |||
| border-bottom: 1px solid #F9F9F9; | |||
| @@ -178,8 +202,11 @@ | |||
| text-align: left; | |||
| } | |||
| .people{ | |||
| margin-top: 20rpx; | |||
| padding-bottom: 130rpx; | |||
| border-radius:16rpx; | |||
| background: rgba(255, 245, 240, 1); | |||
| margin-top: 20rpx; | |||
| padding:0 10rpx; | |||
| margin-bottom: 130rpx; | |||
| } | |||
| .btns{ | |||
| padding:33rpx; | |||
| @@ -224,11 +251,14 @@ | |||
| font-size: 26rpx; | |||
| text-align: center; | |||
| line-height: 200rpx; | |||
| margin-top: 30rpx; | |||
| background: linear-gradient(90deg,rgba(236,59,45,1) 0%,rgba(248,98,52,1) 100%); | |||
| box-shadow: 0px 8px 8px 1px rgba(246,93,51,0.32); | |||
| margin: 30rpx auto 0; | |||
| color: #fff!important; | |||
| } | |||
| .helpDiscount image{ | |||
| display: block; | |||
| width: 200rpx; | |||
| height: 200rpx; | |||
| } | |||
| .helpDiscount::after{ border: none; } | |||
| .success{ | |||
| margin-top: 50rpx; | |||
| @@ -363,7 +363,7 @@ Page({ | |||
| }); | |||
| } else if (err.code == "3001") { | |||
| wx.showToast({ | |||
| title: "领取达到上限", | |||
| title: "超过限购条件", | |||
| image: imgurl.fail.url, | |||
| duration: 2000, | |||
| mask: false | |||
| @@ -6,7 +6,7 @@ | |||
| </i-tabs> | |||
| <view class='cards clearfix'> | |||
| <view class="nocoupon" wx:if="{{list.length==0}}"> | |||
| <image src="{{couponUrl}}" mode="widthFix" lazy-load="true" /> | |||
| <image src="{{couponUrl}}" mode="aspectFill" lazy-load="true" /> | |||
| <text class="txt001">请您敬请期待</text> | |||
| <text class='txt002'>我们正在筹备一大波优惠活动</text> | |||
| <navigator class='nav' url="/pages/index/index" open-type="switchTab" hover-class="other-navigator-hover"> | |||
| @@ -41,17 +41,6 @@ Page({ | |||
| data: {} | |||
| }) | |||
| .then(res=>{ | |||
| // if true 则开启特享礼遇 | |||
| if (res.data.discountEnable) { | |||
| that.setData({ | |||
| discountEnable: true | |||
| }) | |||
| } | |||
| else { | |||
| that.setData({ | |||
| discountEnable: false | |||
| }) | |||
| } | |||
| that.setData({ | |||
| flags: 'have', | |||
| rules: JSON.parse(res.data.score.rules).concat(JSON.parse(res.data.score.rules)[1].childs), | |||
| @@ -40,6 +40,6 @@ | |||
| <image class='img' src='{{actUrl}}' mode='widthFix'></image> | |||
| <text class="txt">暂无配置信息</text> | |||
| </view> | |||
| <view class='growthbg' bindtap='gotospecialcourtesy' wx:if="{{discountEnable}}"> | |||
| <view class='growthbg' bindtap='gotospecialcourtesy'> | |||
| <image src='{{growthbgUrl}}' mode='widthFix'></image> | |||
| </view> | |||
| @@ -25,7 +25,6 @@ Page({ | |||
| havePlayEd: app.globalData.havePlayEd, | |||
| staticGamedata: {}, | |||
| showIf: false, | |||
| discountEnable:false, | |||
| page: 1 // 刷新进入页面时已经加载了第一页数据,onReachBottom时 page++,从第2页开始加载 | |||
| }, | |||
| gotodiscountCardList:function(){ | |||
| @@ -38,26 +37,6 @@ Page({ | |||
| url: '/pages/rushToBuy/index', | |||
| }) | |||
| }, | |||
| showSpecial:function(){ | |||
| let that = this; | |||
| Http.get({ | |||
| url: config.api.scoreLevelInfo, | |||
| data: {} | |||
| }) | |||
| .then(res => { | |||
| // if true 则开启特享礼遇 | |||
| if (res.data.discountEnable) { | |||
| that.setData({ | |||
| discountEnable: true | |||
| }) | |||
| } | |||
| else { | |||
| that.setData({ | |||
| discountEnable: false | |||
| }) | |||
| } | |||
| }) | |||
| }, | |||
| qrcode: function (e) { | |||
| var that = this; | |||
| that.setData({ | |||
| @@ -172,8 +151,7 @@ Page({ | |||
| * 生命周期函数--监听页面初次渲染完成 | |||
| */ | |||
| onLoad: function (options) { | |||
| wx.setStorageSync('imgurl', imgurl) | |||
| wx.setStorageSync('imgurl', imgurl) | |||
| if (options.played == "true") { | |||
| this.setData({ | |||
| played: true | |||
| @@ -319,7 +297,6 @@ Page({ | |||
| } | |||
| Http.setToken(res.data.token); | |||
| that.checkUserCarStatus(); | |||
| that.showSpecial(); | |||
| that.getUserInfo(); | |||
| that.getBannerlist(); | |||
| if (app.couponChannelListCallback) { | |||
| @@ -33,6 +33,6 @@ | |||
| <view class="canvas-box"> | |||
| <text class='memberIds' wx:if="{{levelName!='无'}}">{{levelName}}</text> | |||
| <canvas hidden="{{canvasHidden}}" style="width:500rpx;height:460rpx;background:0 0 0 .6;margin:-10rpx auto;overflow:hidden" canvas-id="mycanvas2" /> | |||
| <button class='button' bindtap='mySpecial' wx:if="{{discountEnable}}">特享礼遇</button> | |||
| <button class='button' bindtap='mySpecial'>特享礼遇</button> | |||
| </view> | |||
| </view> | |||
| @@ -57,13 +57,13 @@ Page({ | |||
| if (key == 'all') { | |||
| var variable = { | |||
| pageNum: pageNum, | |||
| pageSize: 5, | |||
| pageSize: 15, | |||
| paymentType: 0 | |||
| }; | |||
| } else { | |||
| var variable = { | |||
| pageNum: pageNum, | |||
| pageSize: 5, | |||
| pageSize: 15, | |||
| orderStatus: key, | |||
| paymentType: 0 | |||
| }; | |||
| @@ -101,8 +101,17 @@ Page({ | |||
| } | |||
| var tmpArr = that.data.list; | |||
| tmpArr.push.apply(tmpArr, res.data.list); | |||
| // 将砍价的状态过滤出来 | |||
| let list = []; | |||
| console.log(tmpArr) | |||
| tmpArr.map(file=>{ | |||
| if (file.orderStatus == 6 || file.orderStatus == 7 || file.orderStatus == 8 || file.orderStatus == 9){}else{ | |||
| list.push(file); | |||
| } | |||
| }) | |||
| console.log(list) | |||
| that.setData({ | |||
| list: tmpArr | |||
| list: list | |||
| }) | |||
| for (let i = 0; i < that.data.list.length; i++) { | |||
| var createDate1 = util.formatTime(that.data.list[i].createDate, "yyyy-MM-dd hh:mm:ss"); | |||
| @@ -125,7 +134,6 @@ Page({ | |||
| }) | |||
| } | |||
| else { | |||
| console.log("加载完成allow_load设置成false"); | |||
| that.setData({ | |||
| loading: true, | |||
| content: "——— 再拉裤子就掉了啦 ———" | |||
| @@ -14,6 +14,7 @@ Page({ | |||
| cardList: [], | |||
| arrays: [], | |||
| showModel: false, | |||
| showInput:false, | |||
| ids: "" | |||
| }, | |||
| @@ -67,6 +68,7 @@ Page({ | |||
| wx.hideLoading(); | |||
| that.setData({ | |||
| showModel: false, | |||
| showInput: false, | |||
| cardid: that.data.cardids, | |||
| ids: "", | |||
| remainingAmount: that.data.remainingAmounts | |||
| @@ -126,7 +128,8 @@ Page({ | |||
| if (res.code == 200) { | |||
| wx.hideLoading(); | |||
| that.setData({ | |||
| showModel: false | |||
| showModel: false, | |||
| showInput: false | |||
| }) | |||
| wx.navigateTo({ | |||
| url: `/pages/paySuccess/paySuccess?data=${JSON.stringify(res.data)}`, | |||
| @@ -171,7 +174,8 @@ Page({ | |||
| }) | |||
| } else if (that.data.inputValue != "" && Number(that.data.remainingAmount) < Number(that.data.inputValue)) { | |||
| that.setData({ | |||
| showModel: true | |||
| showModel: true, | |||
| showInput:'disabled' | |||
| }) | |||
| that.getList(); | |||
| console.log("1111") | |||
| @@ -191,7 +195,8 @@ Page({ | |||
| url: '/pages/discountCardList/discountCardList' | |||
| }) | |||
| this.setData({ | |||
| showModel: false | |||
| showModel: false, | |||
| showInput: false | |||
| }) | |||
| }, | |||
| getList() { | |||
| @@ -239,6 +244,7 @@ Page({ | |||
| showModel: function() { | |||
| this.setData({ | |||
| showModel: false, | |||
| showInput: false, | |||
| cardid: this.data.cardids, | |||
| ids: "", | |||
| remainingAmount: this.data.remainingAmounts | |||
| @@ -6,7 +6,7 @@ | |||
| <text class='txt1'>金额</text> | |||
| <view class='money'> | |||
| <text class='icon'>¥</text> | |||
| <input bindinput="bindKeyInput" class='num' type="digit" focus placeholder="" /> | |||
| <input bindinput="bindKeyInput" disabled='{{showInput}}' class='num' type="digit" focus placeholder="" /> | |||
| <button bindtap='startAuth' hover-class='active'>确认付款</button> | |||
| </view> | |||
| <view class='model' wx:if="{{showModel}}"> | |||
| @@ -2,7 +2,7 @@ | |||
| <image src="{{myspeacialUrl}}" mode='widthFix'></image> | |||
| </view> | |||
| <view class='con'> | |||
| <view class="title">以下为商城<text class='level'>{{level}}</text>对应门店的优惠折扣</view> | |||
| <view class="title">会员等级为<text class='level'>[{{level}}]</text>对应门店的优惠折扣</view> | |||
| </view> | |||
| <view class='cards clearfix'> | |||
| <view class='card' wx:for="{{discountMerchantList}}" wx:key="{{index}}" wx:if="{{discountMerchantList.length>0}}"> | |||
| @@ -22,6 +22,6 @@ | |||
| </view> | |||
| </view> | |||
| <view class='none' wx:if="{{discountMerchantList.length==0}}"> | |||
| 暂无数据 | |||
| 此等级暂未开放折扣 | |||
| </view> | |||
| </view> | |||
| @@ -5,7 +5,7 @@ Page{ | |||
| font-size: 28rpx; | |||
| text-align: center; | |||
| margin-top: 30rpx; | |||
| color: #000; | |||
| color: #fff; | |||
| float:none!important; | |||
| } | |||
| .headerbg image{ | |||
| @@ -164,24 +164,6 @@ Page({ | |||
| }) | |||
| //暂时注释 | |||
| // that.getrun(); | |||
| // 判断是否显示特享礼遇 | |||
| Http.get({ | |||
| url: config.api.scoreLevelInfo, | |||
| data: {} | |||
| }) | |||
| .then(res=>{ | |||
| // if true 则开启特享礼遇 | |||
| if (res.data.discountEnable){ | |||
| that.setData({ | |||
| discountEnable:true | |||
| }) | |||
| } | |||
| else{ | |||
| that.setData({ | |||
| discountEnable: false | |||
| }) | |||
| } | |||
| }) | |||
| }, | |||
| hideQrcode:function(){ | |||
| let that = this; | |||
| @@ -63,7 +63,7 @@ | |||
| </view> | |||
| </navigator> | |||
| <!-- 当商场开启使用折扣按钮的时候, --> | |||
| <navigator url="/pages/specialcourtesy/specialcourtesy" wx:if="{{discountEnable}}"> | |||
| <navigator url="/pages/specialcourtesy/specialcourtesy"> | |||
| <view class="user-btn app-border-bottom"> | |||
| <view> | |||
| <image class='icons' src="{{giftUrl}}" mode='widthFix'></image>特享礼遇</view> | |||
| @@ -76,7 +76,7 @@ | |||
| <view class="margin"></view> | |||
| <!-- <button bindtap="navigateTo" class="user-out-btn">退出登陆</button> --> | |||
| <view bindlongtap='showVersion' class='version'> | |||
| <view wx:if="{{flag=='show'}}">版本号:3.3.2</view> | |||
| <view wx:if="{{flag=='show'}}">版本号:3.3.3</view> | |||
| <view wx:if="{{flag=='hidden'}}"></view> | |||
| </view> | |||
| </view> | |||
| @@ -52,6 +52,10 @@ class HttpBasics { | |||
| err.errMsg = '请求超时,请检查您的网络设置!' | |||
| } else if (err.errMsg == 'request:fail '){ | |||
| err.errMsg = '未检查到您的网络,请检查您的网络设置!' | |||
| } else if (err.code == 1052){ | |||
| wx.switchTab({ | |||
| url: '/pages/index/index', | |||
| }) | |||
| } | |||
| reject(err); | |||
| } | |||
| @@ -84,6 +88,10 @@ class HttpBasics { | |||
| err.errMsg = '请求超时,请检查您的网络设置!' | |||
| } else if (err.errMsg == 'request:fail ') { | |||
| err.errMsg = '未检查到您的网络,请检查您的网络设置!' | |||
| } else if (err.code == 1052) { | |||
| wx.switchTab({ | |||
| url: '/pages/index/index', | |||
| }) | |||
| } | |||
| reject(err); | |||
| }, | |||
| @@ -337,7 +337,7 @@ module.exports = { | |||
| 'name': '' | |||
| }, | |||
| 'icon004': { | |||
| 'url': baseUrl + 'icon004.png', | |||
| 'url': baseUrl + 'icon004.gif', | |||
| 'name': '' | |||
| } | |||
| } | |||