This commit is contained in:
2025-07-02 19:42:16 +08:00
parent a6e4d6e219
commit 93d46459f9
10 changed files with 192 additions and 109 deletions
+5 -6
View File
@@ -36,17 +36,16 @@ function post_file(path, file, file_name, callback) {
//获取保存的cookie
var cookie = load_json("cookie");
//console.log(cookie);
formData.append("cookie", JSON.stringify(cookie)); //插入cookie
if(cookie){
formData.append("cookie", cookie.Value); //插入cookie
}
var re_data = {};
// 发送请求
axios
.post(head_path + path, formData, {
headers: {
"Content-Type": "multipart/form-data", // 这里实际上可以省略,因为FormData会被正确识别
},
})
.post(head_path + path, formData)
.then((response) => {
//console.log(response)
re_data["statusCode"] = response.status;