...
|
...
|
@@ -43,15 +43,11 @@ export default class yas { |
|
|
uploadData(params) {
|
|
|
let sid = '';
|
|
|
let globalData = getGlobalData();
|
|
|
|
|
|
if (this.app && this.app.globalData) {
|
|
|
sid = globalData.sid || '';
|
|
|
}
|
|
|
|
|
|
// 开发环境不上报
|
|
|
if (this.devEnv) {
|
|
|
return console.log(params);
|
|
|
}
|
|
|
|
|
|
return Taro.request({
|
|
|
url: config.domains.yasHost,
|
|
|
data: { _mlogs: JSON.stringify(params) },
|
...
|
...
|
@@ -117,12 +113,16 @@ export default class yas { |
|
|
}
|
|
|
},
|
|
|
complete() {
|
|
|
self.app.globalData = self.app.globalData || {};
|
|
|
let globalData = getGlobalData();
|
|
|
let userData = globalData.userInfo || {};
|
|
|
|
|
|
if (!Object.keys(userData).length) {
|
|
|
userData = Taro.getStorageSync('userInfo') || {};
|
|
|
}
|
|
|
|
|
|
let ch = self.app.globalData.ch || '';
|
|
|
let uid = self.app.globalData.userInfo && self.app.globalData.userInfo.uid || '';
|
|
|
let ch = globalData.ch || '';
|
|
|
let uid = userData.uid || '';
|
|
|
|
|
|
// ch = self.app.getUnion_type() || ch;
|
|
|
self.deviceInfo.ch = ch;
|
|
|
return resolve(self.uploadData({
|
|
|
status: statusInfo,
|
...
|
...
|
@@ -132,7 +132,7 @@ export default class yas { |
|
|
ts: new Date().getTime(),
|
|
|
op: event,
|
|
|
uid: uid,
|
|
|
sid: self.app.globalData.sid || ''
|
|
|
sid: globalData.sid || ''
|
|
|
}]
|
|
|
}));
|
|
|
}
|
...
|
...
|
|