...
|
...
|
@@ -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 || '';
|
...
|
...
|
|