Commit 7bef1b48 by 谢中龙

二维码处理,全部会员

parent 4a080aed
{ {
"navigationBarTitleText": "我的招募", "navigationBarTitleText": "全部会员",
"usingComponents": {} "usingComponents": {}
} }
\ No newline at end of file
...@@ -20,9 +20,6 @@ wxService.page({ ...@@ -20,9 +20,6 @@ wxService.page({
* 生命周期函数--监听页面加载 * 生命周期函数--监听页面加载
*/ */
onLoad: function (options) { onLoad: function (options) {
console.log('uinfo----', wx.getStorageSync('guidBaseInfo'))
console.log('guidInfo----', wx.getStorageSync('guidInfo'))
const currentEnv = wx.getStorageSync('_qyWeChat'); const currentEnv = wx.getStorageSync('_qyWeChat');
if (currentEnv) { if (currentEnv) {
this.getEnterpriseQrcode(); this.getEnterpriseQrcode();
...@@ -65,24 +62,31 @@ wxService.page({ ...@@ -65,24 +62,31 @@ wxService.page({
}, },
//获取企业二维码 //获取企业二维码
getEnterpriseQrcode(){ getEnterpriseQrcode(){
wx.qy.getQrCode({ let guideCodeImg = wx.getStorageSync('guideCodeImg');
success: res => { if (!guideCodeImg){
console.log('获取员工二维码---', res) wx.qy.getQrCode({
this.setData({ success: res => {
codeImg: res.qrCode this.setData({
}); codeImg: res.qrCode
}, });
fail: res => { wx.setStorageSync('guideCodeImg', res.qrCode);
console.log('获取员工二维码失败---', res) },
} fail: res => {
}); console.log('获取员工二维码失败---', res)
}
});
}
else{
this.setData({
codeImg: guideCodeImg
});
}
}, },
//获取头像 //获取头像
getAvator(){ getAvator(){
wx.qy.getAvatar({ wx.qy.getAvatar({
success: res => { success: res => {
console.log('获取员工二头像---', res)
this.setData({ this.setData({
avator: res.avatar avator: res.avatar
}); });
......
...@@ -35,6 +35,12 @@ wxService.page({ ...@@ -35,6 +35,12 @@ wxService.page({
onShow: function () { onShow: function () {
}, },
//跳转到我的全部会员
onTapToMyMemberList(){
wx.navigateTo({
url: '/shoppingGuid/page/pages/myMemberList/myMemberList',
});
},
//点击事件 //点击事件
onTapExpandOrInpand(e){ onTapExpandOrInpand(e){
......
...@@ -16,6 +16,7 @@ ...@@ -16,6 +16,7 @@
data-index="{{idx}}" data-index="{{idx}}"
data-item="{{item}}" data-item="{{item}}"
wx:for-item="item">{{item.name}}</view> wx:for-item="item">{{item.name}}</view>
</view> </view>
<!-- 标签s --> <!-- 标签s -->
<view class='tags'> <view class='tags'>
...@@ -31,7 +32,7 @@ ...@@ -31,7 +32,7 @@
wx:if="{{idx < 3}}" wx:if="{{idx < 3}}"
wx:for-item="item">{{item.name}}</view> wx:for-item="item">{{item.name}}</view>
</view> </view>
<view class='rg' bindtap='onTapExpandOrInpand'>展开></view> <view class='rg' bindtap='onTapExpandOrInpand'>{{isOpen ? "收起" : "展开"}}</view>
</view> </view>
</view> </view>
</view> </view>
...@@ -80,5 +81,6 @@ ...@@ -80,5 +81,6 @@
<view class='empty' wx:if="{{tags.length == 0}}"> <view class='empty' wx:if="{{tags.length == 0}}">
{{noTag ? "暂无数据~" : "数据加载中.."}} {{noTag ? "暂无数据~" : "数据加载中.."}}
</view> </view>
<!-- 悬浮我的全部会员 -->
<view class='all-members' bindtap='onTapToMyMemberList'>全部</view>
...@@ -228,4 +228,21 @@ view{ ...@@ -228,4 +228,21 @@ view{
.list .list-item .rg-info .info-desc{ .list .list-item .rg-info .info-desc{
color: #999999; color: #999999;
font-size: 24rpx; font-size: 24rpx;
}
/* w我的全部会员 */
.all-members{
position: fixed;
width: 80rpx;
height: 80rpx;
background: rgba(0, 0, 0, 0.5);
border-radius: 50%;
bottom: 120rpx;
right: 30rpx;
z-index: 2;
display: flex;
align-items: center;
justify-content: center;
color: #ffffff;
font-size: 24rpx;
} }
\ No newline at end of file
...@@ -67,6 +67,7 @@ wxService.page({ ...@@ -67,6 +67,7 @@ wxService.page({
this.setData({ this.setData({
code: res.code code: res.code
}); });
wx.removeStorageSync('guideCodeImg');
this.jscode2session(res.code); this.jscode2session(res.code);
}, },
fail: res => { fail: res => {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment