This commit is contained in:
shijingjing
2022-08-17 09:28:57 +08:00
parent d14371d7dc
commit 9a575cff69

View File

@@ -284,6 +284,7 @@ export default {
} }
}, },
toEdit(row) { toEdit(row) {
console.log(row);
this.form = {...row} this.form = {...row}
if(this.form?.validRangeData) { if(this.form?.validRangeData) {
this.girdInfoList = JSON.parse(this.form.validRangeData) this.girdInfoList = JSON.parse(this.form.validRangeData)
@@ -453,7 +454,7 @@ export default {
beforeSelectTree() { beforeSelectTree() {
this.treeObj.checkedKeys = []; this.treeObj.checkedKeys = [];
this.instance.post(`/app/appgirdinfo/listAll3`, null, null).then((res) => { this.instance.post(`/app/appgirdinfo/listAll3`, null, null).then((res) => {
if (res.code == 0) { if (res?.code == 0) {
let tree = this.girdToTree(res.data); let tree = this.girdToTree(res.data);
this.treeObj.treeList = this.addKey(tree) this.treeObj.treeList = this.addKey(tree)
@@ -500,12 +501,10 @@ export default {
}, },
onCheckChange(e) { onCheckChange(e) {
this.girdInfoList.forEach((item) => { this.girdInfoList?.forEach((item) => {
if(item.id == e.id) { if(item.id == e.id) {
console.log(111);
this.$refs.tree.setChecked(e.id, false); this.$refs.tree.setChecked(e.id, false);
} else { } else {
console.log(222);
this.$refs.tree.setChecked(e.id, true); this.$refs.tree.setChecked(e.id, true);
} }
}) })