Authored by huangyi

更新getUid 改为getUser

... ... @@ -45,7 +45,7 @@
"file-loader": "^1.1.11",
"url-loader": "^1.0.1",
"webpack": "^4.17.2",
"webpack-cli": "^2.0.14",
"webpack-cli": "^3.1.2",
"weixin-js-sdk": "^1.3.3",
"fetch-jsonp": "^1.1.3",
"eslint": "^3.19.0",
... ...
... ... @@ -136,11 +136,13 @@ export default {
resolve(obj);
});
} else if (env === 'app') {
return Promise.all([_appGetUid(), _appGetSessionKey()]).then(function (r) {
obj.uid = r[0]
obj.sessionKey = r[1]
resolve(obj);
})
document.addEventListener('deviceready', () => {
return Promise.all([_appGetUid(), _appGetSessionKey()]).then(function (r) {
obj.uid = r[0]
obj.sessionKey = r[1]
resolve(obj);
})
});
} else {
obj.uid = Number(cookies.cookie('app_uid')) || Number(getQueryObj().uid) || 0;
obj.sessionKey = cookies.cookie('app_session_key') || getQueryObj().session_key || '';
... ...