|
@@ -117,19 +117,19 @@ service.interceptors.request.use(
|
|
* params: { data, params, raw }
|
|
* params: { data, params, raw }
|
|
* content
|
|
* content
|
|
*/
|
|
*/
|
|
- const header = encryptionFun({raw, body, appId: 'web_client', AppSecret: 'fa0fc0b5098b974b'})
|
|
|
|
|
|
+ const { noSign, ...header} = encryptionFun({raw, body, appId: 'web_client', AppSecret: 'fa0fc0b5098b974b'})
|
|
const content = {
|
|
const content = {
|
|
data: config.data,
|
|
data: config.data,
|
|
params: config.params,
|
|
params: config.params,
|
|
body,
|
|
body,
|
|
raw,
|
|
raw,
|
|
|
|
+ noSign,
|
|
config,
|
|
config,
|
|
browserInfo: getBrowserInfo()
|
|
browserInfo: getBrowserInfo()
|
|
}
|
|
}
|
|
errorData.push({
|
|
errorData.push({
|
|
time: header.timestamp,
|
|
time: header.timestamp,
|
|
url: config.url,
|
|
url: config.url,
|
|
- mark: generateUUID(),
|
|
|
|
content
|
|
content
|
|
})
|
|
})
|
|
Object.assign(config.headers, header)
|
|
Object.assign(config.headers, header)
|
|
@@ -257,7 +257,7 @@ service.interceptors.response.use(
|
|
} else {
|
|
} else {
|
|
if (_index > -1) {
|
|
if (_index > -1) {
|
|
// 保存错误信息
|
|
// 保存错误信息
|
|
- sendError({ content: JSON.stringify(errorData[_index].content), mark: errorData[_index].mark })
|
|
|
|
|
|
+ sendError({ content: JSON.stringify(errorData[_index].content), mark: errorData[_index].time + '' })
|
|
// 移除
|
|
// 移除
|
|
errorData.splice(_index, 1)
|
|
errorData.splice(_index, 1)
|
|
}
|
|
}
|
|
@@ -349,14 +349,14 @@ function getBrowserInfo() {
|
|
|
|
|
|
if (ua.includes("edge")) {
|
|
if (ua.includes("edge")) {
|
|
// edge 浏览器
|
|
// edge 浏览器
|
|
- browserName = "edge";
|
|
|
|
- fullVersion = ua.split("edge/")[1].split(" ")[0];
|
|
|
|
|
|
+ browserName = "Edg";
|
|
|
|
+ fullVersion = ua.split("Edg/")[1].split(" ")[0];
|
|
} else if (ua.includes("qqbrowser")) {
|
|
} else if (ua.includes("qqbrowser")) {
|
|
browserName = 'QQ浏览器';
|
|
browserName = 'QQ浏览器';
|
|
- fullVersion = ua.split("qqbrowser/")[1].split(" ")[0];
|
|
|
|
|
|
+ fullVersion = ua.split("QQbrowser/")[1].split(" ")[0];
|
|
} else if (ua.includes("ubrowser")) {
|
|
} else if (ua.includes("ubrowser")) {
|
|
browserName = 'UC浏览器';
|
|
browserName = 'UC浏览器';
|
|
- fullVersion = ua.split("ubrowser/")[1].split(" ")[0];
|
|
|
|
|
|
+ fullVersion = ua.split("Ubrowser/")[1].split(" ")[0];
|
|
} else if (ua.includes("Firefox")) {
|
|
} else if (ua.includes("Firefox")) {
|
|
// Firefox 浏览器
|
|
// Firefox 浏览器
|
|
browserName = "Firefox";
|
|
browserName = "Firefox";
|