@@ -29,6 +29,8 @@ Page({ | |||||
staticGamedata: {}, | staticGamedata: {}, | ||||
showIf: false, | showIf: false, | ||||
showPages: false, | showPages: false, | ||||
display: 'none', | |||||
display1:'none', | |||||
page: 1 // 刷新进入页面时已经加载了第一页数据,onReachBottom时 page++,从第2页开始加载 | page: 1 // 刷新进入页面时已经加载了第一页数据,onReachBottom时 page++,从第2页开始加载 | ||||
}, | }, | ||||
// 我的卡包 | // 我的卡包 | ||||
@@ -198,11 +200,37 @@ Page({ | |||||
havePlayEd: app.globalData.havePlayEd ? app.globalData.havePlayEd : false | havePlayEd: app.globalData.havePlayEd ? app.globalData.havePlayEd : false | ||||
}) | }) | ||||
let num = wx.getStorageSync('couponNum'); | let num = wx.getStorageSync('couponNum'); | ||||
let num1 = wx.getStorageSync('couponNum2'); | |||||
if (num == 'couponNum') { | if (num == 'couponNum') { | ||||
wx.showTabBarRedDot({ | wx.showTabBarRedDot({ | ||||
index: 2 | index: 2 | ||||
}) | }) | ||||
}; | |||||
this.setData({ | |||||
display: "block" | |||||
}) | |||||
}else{ | |||||
wx.hideTabBarRedDot({ | |||||
index: 2 | |||||
}) | |||||
this.setData({ | |||||
display: "none" | |||||
}) | |||||
} | |||||
if (num1 == 'couponNum2') { | |||||
wx.showTabBarRedDot({ | |||||
index: 2 | |||||
}) | |||||
this.setData({ | |||||
display1: "block" | |||||
}) | |||||
} else { | |||||
wx.hideTabBarRedDot({ | |||||
index: 2 | |||||
}) | |||||
this.setData({ | |||||
display1: "none" | |||||
}) | |||||
} | |||||
}, | }, | ||||
// 会员码获取 | // 会员码获取 | ||||
getmemberId: function(token) { | getmemberId: function(token) { | ||||
@@ -22,18 +22,20 @@ | |||||
<image src='{{icon0005}}'></image> | <image src='{{icon0005}}'></image> | ||||
<text>品牌门店</text> | <text>品牌门店</text> | ||||
</view> | </view> | ||||
<view bindtap='mycard'> | |||||
<view bindtap='qrcode'> | |||||
<image src='{{icon0008}}'></image> | |||||
<text>会员权益</text> | |||||
</view> | |||||
<view bindtap='mycard'> | |||||
<image src='{{icon0006}}'></image> | <image src='{{icon0006}}'></image> | ||||
<i class="red" style="display:{{display1}}"></i> | |||||
<text>我的卡包</text> | <text>我的卡包</text> | ||||
</view> | </view> | ||||
<view bindtap='mycoupon'> | |||||
<view bindtap='mycoupon'> | |||||
<image src='{{icon0007}}'></image> | <image src='{{icon0007}}'></image> | ||||
<i class="red" style="display:{{display}}"></i> | |||||
<text>我的券包</text> | <text>我的券包</text> | ||||
</view> | </view> | ||||
<view bindtap='qrcode'> | |||||
<image src='{{icon0008}}'></image> | |||||
<text>会员权益</text> | |||||
</view> | |||||
</view> | </view> | ||||
<!-- 小游戏暂时注释 --> | <!-- 小游戏暂时注释 --> | ||||
<view class='game' bindtap="gotogame" wx-if="{{showIf}}"> | <view class='game' bindtap="gotogame" wx-if="{{showIf}}"> | ||||
@@ -12,7 +12,18 @@ | |||||
line-height: 88rpx; | line-height: 88rpx; | ||||
overflow: hidden; | overflow: hidden; | ||||
} | } | ||||
.red{ | |||||
position:absolute; | |||||
width:13rpx; | |||||
height:13rpx; | |||||
border-radius:50%; | |||||
background:red; | |||||
right:-50rpx; | |||||
top:19rpx; | |||||
left:0; | |||||
margin:auto; | |||||
display: none; | |||||
} | |||||
page { | page { | ||||
width: 100%; | width: 100%; | ||||
height: auto !important; | height: auto !important; | ||||
@@ -43,6 +54,7 @@ page { | |||||
.section >view{ | .section >view{ | ||||
width: 25%; | width: 25%; | ||||
display: inline-block; | display: inline-block; | ||||
position: relative; | |||||
} | } | ||||
.section >view image { | .section >view image { | ||||
display: block; | display: block; | ||||