|
|
|
@ -103,7 +103,7 @@ Page({ |
|
|
|
app.userInfo = result.data |
|
|
|
app.globalData.token = authorization |
|
|
|
storage.put('Authorization', app.globalData.token) |
|
|
|
if(app.userInfo.factoryId && this.data.metaData && app.userInfo.factoryId != this.data.metaData.factoryId){ |
|
|
|
if(app.userInfo.factoryId && this.data.metaData){ |
|
|
|
Dialog.alert({ title: '温馨提示', message: '您已经绑定过工厂了,现在就进入?' }).then(() => { |
|
|
|
wx.redirectTo({ url: '/pages/index/index' }) |
|
|
|
}) |
|
|
|
@ -117,17 +117,15 @@ Page({ |
|
|
|
} else { |
|
|
|
this.setData({ loging: false, metaData: this.data.metaData }) |
|
|
|
} |
|
|
|
} else { |
|
|
|
if(app.userInfo.factoryId){ |
|
|
|
if(!result.data.isSaasPerssion){ |
|
|
|
Dialog.alert({ title: '温馨提示', message: '您的打包站还在授权中,请耐心等待,或者联系相关客服人员?' }).then(() => { |
|
|
|
}) |
|
|
|
return |
|
|
|
} |
|
|
|
wx.redirectTo({ url: '/pages/index/index' }) |
|
|
|
} else { |
|
|
|
wx.redirectTo({ url: '/pages/client/index/index' }) |
|
|
|
} else if(app.userInfo.factoryId){ |
|
|
|
if(!result.data.isSaasPerssion){ |
|
|
|
Dialog.alert({ title: '温馨提示', message: '您的打包站还在授权中,请耐心等待,或者联系相关客服人员?' }).then(() => { |
|
|
|
}) |
|
|
|
return |
|
|
|
} |
|
|
|
wx.redirectTo({ url: '/pages/index/index' }) |
|
|
|
} else { |
|
|
|
wx.redirectTo({ url: '/pages/client/index/index' }) |
|
|
|
} |
|
|
|
}).catch(err => { |
|
|
|
wx.hideLoading() |
|
|
|
|