设置 headers content-type 不管用
export const SetPrint = (printname) => { // 检查打印插件是否安装
return request({
headers: {
"Content-Type": "application/x-www-form-urlencoded",
},
url: '/print/PRINT/SetPrint',
method: 'post',
printname:printname
})
}
请求头就是这样设置的,但是你没用进一步详细描述你说的“不行”是哪一种,所以没法帮你判断
扫一扫访问 Blade技术社区 移动端