|
@@ -554,10 +554,11 @@ export default {
|
|
|
objectdata.millTypeCode = this.detail.millTypeCode;
|
|
|
}
|
|
|
|
|
|
+
|
|
|
const API = !this.isEdit
|
|
|
- ? createEngineMill(objectdata)
|
|
|
- : updateWindEngineMill(objectdata);
|
|
|
-
|
|
|
+ ? createEngineMill(objectdata) //新增
|
|
|
+ : updateWindEngineMill(objectdata); //编辑
|
|
|
+ console.log(this.isEdit,API,'APIAPI');
|
|
|
API.then((res) => {
|
|
|
this.nuedialog = false;
|
|
|
this.onSubmit();
|
|
@@ -570,10 +571,12 @@ export default {
|
|
|
resetForm(formName) {
|
|
|
this.$refs[formName].resetFields();
|
|
|
this.nuedialog = false;
|
|
|
+ this.isEdit = false;
|
|
|
},
|
|
|
handleClose(done) {
|
|
|
this.$refs.ruleForm.resetFields();
|
|
|
this.nuedialog = false;
|
|
|
+ this.isEdit = false;
|
|
|
done();
|
|
|
},
|
|
|
|