|
@@ -1,22 +1,22 @@
|
|
|
function loginMsg(res) {
|
|
|
- wx.removeStorageSync('auth')
|
|
|
- wx.removeStorageSync('userauth');
|
|
|
- wx.removeStorageSync('siteP');
|
|
|
- wx.removeStorageSync('banner_list');
|
|
|
- wx.removeStorageSync('templetList');
|
|
|
- wx.setStorageSync('isAgree', true)
|
|
|
- wx.setStorageSync('account_list', res.account_list);
|
|
|
- if (res.account_list.length == 1) {
|
|
|
+ wx.removeStorageSync('auth')
|
|
|
+ wx.removeStorageSync('userauth');
|
|
|
+ wx.removeStorageSync('siteP');
|
|
|
+ wx.removeStorageSync('banner_list');
|
|
|
+ wx.removeStorageSync('templetList');
|
|
|
+ wx.setStorageSync('isAgree', true)
|
|
|
+ wx.setStorageSync('account_list', res.account_list);
|
|
|
+ if (res.account_list.length == 1) {
|
|
|
wx.removeStorageSync('userrole')
|
|
|
- wx.setStorageSync('userrole', res.account_list[0].usertype == 1 ? '业务员' : '经销商');
|
|
|
- wx.removeStorageSync('userMsg')
|
|
|
- wx.setStorageSync('userMsg', res.account_list[0])
|
|
|
- init();
|
|
|
- } else {
|
|
|
- wx.redirectTo({
|
|
|
- url: './selectSite',
|
|
|
- })
|
|
|
- }
|
|
|
+ wx.setStorageSync('userrole', res.account_list[0].usertype == 1 ? '业务员' : '经销商');
|
|
|
+ wx.removeStorageSync('userMsg')
|
|
|
+ wx.setStorageSync('userMsg', res.account_list[0])
|
|
|
+ init();
|
|
|
+ } else {
|
|
|
+ wx.redirectTo({
|
|
|
+ url: './selectSite',
|
|
|
+ })
|
|
|
+ }
|
|
|
}
|
|
|
|
|
|
function init() {
|
|
@@ -76,6 +76,18 @@ function init() {
|
|
|
url: '/pages/tabbar/home/index'
|
|
|
})
|
|
|
})
|
|
|
+ _Http.basic({
|
|
|
+ "classname": "sysmanage.develop.optiontype.optiontype",
|
|
|
+ "method": "optiontypeselect",
|
|
|
+ "content": {
|
|
|
+ "typename": "statuscolors"
|
|
|
+ }
|
|
|
+ }).then(res => {
|
|
|
+ if (res.code != '1') return;
|
|
|
+ res.data.forEach(v => {
|
|
|
+ _Http.sColors[v.value] = v.remarks
|
|
|
+ })
|
|
|
+ });
|
|
|
}
|
|
|
|
|
|
/* 站点数据查询 */
|