修改bug

20240109-yw
yuanwei 1 year ago
parent e1ddef2aa8
commit e458463f3d

@ -300,6 +300,7 @@ export default {
if(!this.inputQuery.id){ if(!this.inputQuery.id){
return return
} }
this.query.setFk = this.inputQuery.id
this.loading = true; this.loading = true;
listSetDetail(this.query) // listSetDetail(this.query) //
.then((response) => { .then((response) => {
@ -366,13 +367,31 @@ export default {
}); });
}, },
selectProductFunction(){ selectProductFunction(){
if(!this.inputQuery.id){ if(!this.inputQuery.id){
if (this.actDateRange !== null) {
this.inputQuery.startDate = this.actDateRange[0]+" 00:00:00";
this.inputQuery.endDate = this.actDateRange[1]+" 23:59:59";
} else {
this.inputQuery.startDate = null;
this.inputQuery.endDate = null;
}
saveSet(this.inputQuery,"add").then((response) => {
if(response.code == 20000){
this.inputQuery.id = response.data.id;
this.relationId = this.inputQuery.id;
this.productVisible = true;
}else{
this.$message.error(response.message);
}
this.$message.error("请先添加规则"); })
return; .catch(() => {
} this.$message.error("添加失败");
this.relationId = this.inputQuery.id; });
this.productVisible = true; }else{
this.relationId = this.inputQuery.id;
this.productVisible = true;
}
}, },
findMethod(query) { findMethod(query) {
this.fromOptions = []; this.fromOptions = [];
@ -404,7 +423,7 @@ export default {
saveSet(this.inputQuery,"add").then((response) => { saveSet(this.inputQuery,"add").then((response) => {
if(response.code == 20000){ if(response.code == 20000){
this.inputQuery.id = response.data.id; this.inputQuery.id = response.data.id;
this.$message.success("保存成功!"); this.closeDialog()
}else{ }else{
this.$message.error(response.message); this.$message.error(response.message);
} }
@ -416,7 +435,7 @@ export default {
}else{ }else{
saveSet(this.inputQuery,"edit").then((response) => { saveSet(this.inputQuery,"edit").then((response) => {
if(response.code == 20000){ if(response.code == 20000){
this.$message.success("修改成功!"); this.closeDialog()
}else{ }else{
this.$message.error(response.message); this.$message.error(response.message);
} }

Loading…
Cancel
Save