迁移oa部分页面:施工进度和每日报工
This commit is contained in:
@@ -19,6 +19,8 @@ const request = config => {
|
||||
url = url.slice(0, -1)
|
||||
config.url = url
|
||||
}
|
||||
// 打印请求体
|
||||
console.log('[oaRequest] 请求体:', config)
|
||||
return new Promise((resolve, reject) => {
|
||||
uni.request({
|
||||
method: config.method || 'get',
|
||||
@@ -29,6 +31,8 @@ const request = config => {
|
||||
dataType: 'json'
|
||||
}).then(response => {
|
||||
let [error, res] = response
|
||||
// 打印返回值
|
||||
console.log('[oaRequest] 返回值:', res)
|
||||
if (error) {
|
||||
console.log(error)
|
||||
toast('后端接口连接异常')
|
||||
|
||||
Reference in New Issue
Block a user