Feat(云灵AI):对话接口对接完成
This commit is contained in:
@@ -85,6 +85,11 @@ function baseRequest(options) {
|
||||
|
||||
// 发起请求
|
||||
return http[options.method](url, _params).then(res => {
|
||||
// AI对话某个请求返回为空需要处理这种情况
|
||||
if (['get', 'GET'].includes(options.method) && _params.params.isNoNeedPublicErrorNotification === 1) {
|
||||
console.log('----')
|
||||
return Promise.resolve({})
|
||||
}
|
||||
const resData = res.data || {};
|
||||
if (res.statusCode !== 200) {
|
||||
return Promise.reject({msg: "请求失败", res, resData});
|
||||
|
||||
Reference in New Issue
Block a user