Commit a89bb983 by 高淑倩

add: 引导页弹框_icon

parent 6989fd5b
...@@ -19,12 +19,18 @@ Component({ ...@@ -19,12 +19,18 @@ Component({
userInfo: {}, userInfo: {},
hasUserInfo: false, hasUserInfo: false,
env: envInfo.env, env: envInfo.env,
checkAll: false,
}, },
/** /**
* 组件的方法列表 * 组件的方法列表
*/ */
methods: { methods: {
checkAll() {
this.setData({
checkAll: !this.data.checkAll
})
},
handelToMemberRules() { handelToMemberRules() {
wxService.router('/pages/memberRules/memberRules') wxService.router('/pages/memberRules/memberRules')
}, },
...@@ -35,10 +41,15 @@ Component({ ...@@ -35,10 +41,15 @@ Component({
}) })
}, },
//立即兑换 //立即兑换
query() { query() {},
},
_getUserInfo(res = {}) { _getUserInfo(res = {}) {
if(!this.data.checkAll) {
wx.showToast({
title: '请同意会员规则',
icon: 'none'
})
return false
}
this.setData({ this.setData({
isAuthorization: false isAuthorization: false
}) })
...@@ -53,11 +64,9 @@ Component({ ...@@ -53,11 +64,9 @@ Component({
} else { } else {
wx.setStorageSync('token', '') wx.setStorageSync('token', '')
} }
wx.setStorageSync('_baseUserInfo', data) wx.setStorageSync('_baseUserInfo', data)
// 存储用户开卡状态 // 存储用户开卡状态
wx.setStorageSync('memberActivateStatus', data.memberActivateStatus) wx.setStorageSync('memberActivateStatus', data.memberActivateStatus)
this.setUserInfo() this.setUserInfo()
}).catch(err=> { }).catch(err=> {
if (err) { if (err) {
...@@ -67,18 +76,14 @@ Component({ ...@@ -67,18 +76,14 @@ Component({
}) })
} }
}) })
} else { } else {
console.log('点击了取消') console.log('点击了取消')
this.setData({ this.setData({
isAuthorization: false isAuthorization: false
}) })
} }
}, },
setUserInfo (e) { setUserInfo () {
console.log('开卡')
// 判断有无开卡 // 判断有无开卡
const memberActivateStatus = wx.getStorageSync('memberActivateStatus') const memberActivateStatus = wx.getStorageSync('memberActivateStatus')
// 没有开卡并且需要开卡 // 没有开卡并且需要开卡
...@@ -102,7 +107,6 @@ Component({ ...@@ -102,7 +107,6 @@ Component({
wxService.router('/pages/userCenter/userCenter').replace() wxService.router('/pages/userCenter/userCenter').replace()
} }
}, 200) }, 200)
} }
} }
}) })
...@@ -10,10 +10,9 @@ ...@@ -10,10 +10,9 @@
<button type='primary' bindgetuserinfo="_getUserInfo" open-type='getUserInfo' class='agree' >同意</button> <button type='primary' bindgetuserinfo="_getUserInfo" open-type='getUserInfo' class='agree' >同意</button>
<view class='rule-wrap'> <view class='rule-wrap'>
<view class='agree-rule'> <view class='agree-rule'>
<!--<label class="radio"> <view class="agree-icon"><icon size="18" type="{{checkAll ? 'success' : 'circle'}}" bindtap="checkAll"></icon></view>
<radio checked="{{preferentialType}}" name="preferentialTypeCheck" value="0" /> <view><text>我已阅读并同意</text><text class='rule-text' bindtap="handelToMemberRules">《会员规则》</text></view>
</label>--> </view>
我已阅读并同意 <text class='rule-text' bindtap="handelToMemberRules">《会员规则》</text></view>
</view> </view>
<view class='close' bindtap='close'> <view class='close' bindtap='close'>
<image src='/assets/imgs/close.png'></image> <image src='/assets/imgs/close.png'></image>
......
...@@ -56,6 +56,10 @@ ...@@ -56,6 +56,10 @@
.agree-rule{ .agree-rule{
font-size: 22rpx; font-size: 22rpx;
color: #666666; color: #666666;
display: flex;
}
.agree-icon{
margin-right: 10rpx;
} }
.rule-text{ .rule-text{
color: #05c35b; color: #05c35b;
......
const PROJECT_ENV = 'dev' // 生产 prod, 测试 dev const PROJECT_ENV = 'dev' // 生产 prod, 测试 dev, 预生产 pre
const needMock = '' // const needMock = '' //
// appid_dev_wx wxc3b64b09b1d3dfc2 // appid_dev_wx wxc3b64b09b1d3dfc2
// appid_711 wx358b56af62edbde1 // appid_pre_711 wx358b56af62edbde1
// 711 预备发生产环境 // 711 预备发生产环境
// 后台地址 : https://crm-b.bigaka.com/api // 后台地址 : https://crm-b.bigaka.com/api
// brandId : 2005 // brandId : 2005
// const devCtx = 'http://111.231.86.64' // const devCtx = 'http://111.231.86.64'
// const devCtx = 'http://buyer.devapi.bigaka.net' const devCtx = 'http://buyer.devapi.bigaka.net' // 开发环境
const devCtx = 'https://crm-b.bigaka.com/api' const preCtx = 'https://crm-b.bigaka.com/api' // 发预生产时解开此注释
const prodCtx = '' // 发生产时解开此注释 const prodCtx = '' // 发生产时解开此注释
const config = { const config = {
dev: devCtx, dev: devCtx,
pre: preCtx,
prod: prodCtx prod: prodCtx
} }
......
...@@ -43,7 +43,7 @@ wxService.page({ ...@@ -43,7 +43,7 @@ wxService.page({
wx.showLoading({ wx.showLoading({
title: '加载中' title: '加载中'
}) })
wxService.get(`/sale/order/findByOrderNo?orderNo=${orderNo}&brandId=2005`).then(res => { wxService.get(`/sale/order/findByOrderNo?orderNo=${orderNo}&brandId=1002`).then(res => {
const {result,data} = res.data const {result,data} = res.data
if(result == 0){ if(result == 0){
wx.hideLoading() wx.hideLoading()
......
...@@ -14,7 +14,7 @@ ...@@ -14,7 +14,7 @@
}, },
"compileType": "miniprogram", "compileType": "miniprogram",
"libVersion": "2.6.6", "libVersion": "2.6.6",
"appid": "wx358b56af62edbde1", "appid": "wxc3b64b09b1d3dfc2",
"tempappid_wx":"wxc3b64b09b1d3dfc2", "tempappid_wx":"wxc3b64b09b1d3dfc2",
"tempappid_711":"wx358b56af62edbde1", "tempappid_711":"wx358b56af62edbde1",
"projectname": "7-Eleven", "projectname": "7-Eleven",
......
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