mirror of
https://github.com/pure-admin/vue-pure-admin.git
synced 2026-01-20 16:53:37 +08:00
refactor: 重构API接口响应格式,带来简洁高效的接口设计 (#1256)
This commit is contained in:
@@ -23,8 +23,8 @@ const submitForm = formEl => {
|
||||
date: validateForm.date // 别的字段
|
||||
});
|
||||
formUpload(formData)
|
||||
.then(({ success }) => {
|
||||
if (success) {
|
||||
.then(({ code }) => {
|
||||
if (code === 0) {
|
||||
message("提交成功", { type: "success" });
|
||||
} else {
|
||||
message("提交失败");
|
||||
|
||||
Reference in New Issue
Block a user