| | |
| | | App({ |
| | | globalData, |
| | | onLaunch: function (op) { |
| | | console.log('options', op.query.scene) |
| | | console.log('options', op.query) |
| | | let pathMap = [ |
| | | '/pages/detailDis/product', |
| | | '/pages/detailDis/case', |
| | |
| | | wx.login({ |
| | | timeout: 5000, |
| | | success: (res) => { |
| | | var userId = null |
| | | if (op.query.scene) { |
| | | let temp = op.query.scene.split('_') |
| | | userId = temp[2] |
| | | } |
| | | if (res.code) { |
| | | //发起网络请求 |
| | | wxLoginCustomer({ |
| | | code: res.code |
| | | code: res.code, |
| | | userId |
| | | |
| | | }).then(res => { |
| | | wx.setStorageSync('token', res.data.token) |
| | | this.globalData.token = res.data.token |