| | |
| | | var info = wx.getStorageSync('info') |
| | | console.log("获取缓存:" + role) |
| | | if (role == 0) { |
| | | wx.redirectTo( |
| | | { |
| | | url: '../user/index' |
| | | } |
| | | ) |
| | | wx.redirectTo( |
| | | { |
| | | url: '../user/index' |
| | | } |
| | | ) |
| | | } |
| | | if (role == 1) { |
| | | wx.redirectTo( |
| | |
| | | wx.setStorageSync('token', res.data.data.token) |
| | | wx.setStorageSync('role', res.data.data.role) |
| | | wx.setStorageSync('id', res.data.data.id) |
| | | wx.setStorageSync('card',res.data.data.time) |
| | | console.log(res.data.data.id) |
| | | if (res.data.data.role == 0) { |
| | | var info=wx.getStorageSync('info') |
| | | var info=wx.getStorageSync('card') |
| | | if (info) { |
| | | wx.redirectTo( |
| | | { |