发布货源页面发布接口 paga/release/release
同一个网络请求接口,在ios上请求返回速度很快,有的android机器上返回速度极慢。
// 提交发布信息
wx.request({
url: config.insert_sources,
method: “POST”,
data: {
sourceType: source_index,
userId: app.globalData.haulUserInfo.id,
loadAddress: form.load_address,
deliveryAddress: form.delivery_address,
detail: form.descript,
pay: form.pay,
load_time: form.date + “”,
chooseOwner: chooseOwner
},
header: {
“content-type”: “application/x-www-form-urlencoded;charset=utf-8”,
//token: app.globalData.token
},
success: res => {
console.log(res)
if (res.data.success) {
wx.showToast({
title: “发布成功”
})
setTimeout(function() {
wx.hideLoading();
wx.navigateTo({
url: “…/sourceList/sourceList?type=” + source_index + “&From=0”
})
}, 1500);
} else {
wx.showToast({
title: ‘发布失败,请检查您的网络’,
})
}
}
})
}