|
|
|
@ -163,41 +163,35 @@ |
|
|
|
}); |
|
|
|
}); |
|
|
|
}, |
|
|
|
}, |
|
|
|
methods: { |
|
|
|
methods: { |
|
|
|
rowSave(row, loading, done) { |
|
|
|
rowSave(row, done, loading) { |
|
|
|
const form = { |
|
|
|
const form = { |
|
|
|
...row, |
|
|
|
...row, |
|
|
|
dictKey: -1, |
|
|
|
dictKey: -1, |
|
|
|
}; |
|
|
|
}; |
|
|
|
add(form).then( |
|
|
|
add(form).then(() => { |
|
|
|
() => { |
|
|
|
|
|
|
|
loading(); |
|
|
|
|
|
|
|
this.onLoadParent(this.pageParent); |
|
|
|
this.onLoadParent(this.pageParent); |
|
|
|
this.$message({ |
|
|
|
this.$message({ |
|
|
|
type: "success", |
|
|
|
type: "success", |
|
|
|
message: "操作成功!" |
|
|
|
message: "操作成功!" |
|
|
|
}); |
|
|
|
}); |
|
|
|
}, |
|
|
|
|
|
|
|
error => { |
|
|
|
|
|
|
|
done(); |
|
|
|
done(); |
|
|
|
|
|
|
|
}, error => { |
|
|
|
window.console.log(error); |
|
|
|
window.console.log(error); |
|
|
|
} |
|
|
|
|
|
|
|
); |
|
|
|
|
|
|
|
}, |
|
|
|
|
|
|
|
rowUpdate(row, index, loading, done) { |
|
|
|
|
|
|
|
update(row).then( |
|
|
|
|
|
|
|
() => { |
|
|
|
|
|
|
|
loading(); |
|
|
|
loading(); |
|
|
|
|
|
|
|
}); |
|
|
|
|
|
|
|
}, |
|
|
|
|
|
|
|
rowUpdate(row, index, done, loading) { |
|
|
|
|
|
|
|
update(row).then(() => { |
|
|
|
this.onLoadParent(this.pageParent); |
|
|
|
this.onLoadParent(this.pageParent); |
|
|
|
this.$message({ |
|
|
|
this.$message({ |
|
|
|
type: "success", |
|
|
|
type: "success", |
|
|
|
message: "操作成功!" |
|
|
|
message: "操作成功!" |
|
|
|
}); |
|
|
|
}); |
|
|
|
}, |
|
|
|
|
|
|
|
error => { |
|
|
|
|
|
|
|
done(); |
|
|
|
done(); |
|
|
|
|
|
|
|
}, error => { |
|
|
|
window.console.log(error); |
|
|
|
window.console.log(error); |
|
|
|
} |
|
|
|
loading(); |
|
|
|
); |
|
|
|
}); |
|
|
|
}, |
|
|
|
}, |
|
|
|
rowDel(row) { |
|
|
|
rowDel(row) { |
|
|
|
this.$confirm("确定将选择数据删除?", { |
|
|
|
this.$confirm("确定将选择数据删除?", { |
|
|
|
@ -287,37 +281,31 @@ |
|
|
|
refreshChange() { |
|
|
|
refreshChange() { |
|
|
|
this.onLoadParent(this.pageParent, this.query); |
|
|
|
this.onLoadParent(this.pageParent, this.query); |
|
|
|
}, |
|
|
|
}, |
|
|
|
rowSaveChild(row, loading, done) { |
|
|
|
rowSaveChild(row, done, loading) { |
|
|
|
add(row).then( |
|
|
|
add(row).then(() => { |
|
|
|
() => { |
|
|
|
|
|
|
|
loading(); |
|
|
|
|
|
|
|
this.onLoadChild(this.pageChild); |
|
|
|
this.onLoadChild(this.pageChild); |
|
|
|
this.$message({ |
|
|
|
this.$message({ |
|
|
|
type: "success", |
|
|
|
type: "success", |
|
|
|
message: "操作成功!" |
|
|
|
message: "操作成功!" |
|
|
|
}); |
|
|
|
}); |
|
|
|
}, |
|
|
|
|
|
|
|
error => { |
|
|
|
|
|
|
|
done(); |
|
|
|
done(); |
|
|
|
|
|
|
|
}, error => { |
|
|
|
window.console.log(error); |
|
|
|
window.console.log(error); |
|
|
|
} |
|
|
|
|
|
|
|
); |
|
|
|
|
|
|
|
}, |
|
|
|
|
|
|
|
rowUpdateChild(row, index, loading, done) { |
|
|
|
|
|
|
|
update(row).then( |
|
|
|
|
|
|
|
() => { |
|
|
|
|
|
|
|
loading(); |
|
|
|
loading(); |
|
|
|
|
|
|
|
}); |
|
|
|
|
|
|
|
}, |
|
|
|
|
|
|
|
rowUpdateChild(row, index, done, loading) { |
|
|
|
|
|
|
|
update(row).then(() => { |
|
|
|
this.onLoadChild(this.pageChild); |
|
|
|
this.onLoadChild(this.pageChild); |
|
|
|
this.$message({ |
|
|
|
this.$message({ |
|
|
|
type: "success", |
|
|
|
type: "success", |
|
|
|
message: "操作成功!" |
|
|
|
message: "操作成功!" |
|
|
|
}); |
|
|
|
}); |
|
|
|
}, |
|
|
|
|
|
|
|
error => { |
|
|
|
|
|
|
|
done(); |
|
|
|
done(); |
|
|
|
|
|
|
|
}, error => { |
|
|
|
window.console.log(error); |
|
|
|
window.console.log(error); |
|
|
|
} |
|
|
|
loading(); |
|
|
|
); |
|
|
|
}); |
|
|
|
}, |
|
|
|
}, |
|
|
|
rowDelChild(row) { |
|
|
|
rowDelChild(row) { |
|
|
|
this.$confirm("确定将选择数据删除?", { |
|
|
|
this.$confirm("确定将选择数据删除?", { |
|
|
|
|