umi-request 替换为 axios

This commit is contained in:
whyour
2023-07-17 23:13:06 +08:00
parent bd166ee794
commit efd4f1d5ab
32 changed files with 215 additions and 214 deletions
+1 -3
View File
@@ -19,9 +19,7 @@ const SaveModal = ({
setLoading(true);
const payload = { ...file, ...values, originFilename: file.title };
request
.post(`${config.apiPrefix}scripts`, {
data: payload,
})
.post(`${config.apiPrefix}scripts`, payload)
.then(({ code, data }) => {
if (code === 200) {
message.success('保存文件成功');