update material
This commit is contained in:
@@ -167,13 +167,15 @@ export default {
|
||||
method,
|
||||
data: {
|
||||
...this.dataForm,
|
||||
...fields
|
||||
...fields,
|
||||
},
|
||||
}).then(({ data: res }) => {
|
||||
console.log("[add&update] res is: ", res);
|
||||
this.$message.success(payload.name === "add" ? "添加成功" : "更新成功");
|
||||
this.$emit("refreshDataList");
|
||||
this.handleClose();
|
||||
if (res.code === 0) {
|
||||
this.$message.success(payload.name === "add" ? "添加成功" : "更新成功");
|
||||
this.$emit("refreshDataList");
|
||||
this.handleClose();
|
||||
} else this.$message.error(res.msg);
|
||||
});
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user