diff --git a/src/views/Transaction.vue b/src/views/Transaction.vue
index 10b5914..2af80eb 100644
--- a/src/views/Transaction.vue
+++ b/src/views/Transaction.vue
@@ -302,7 +302,7 @@
- 需点击
+ 需点击7
@@ -343,6 +343,7 @@ export default {
data() {
return {
count: 0,
+ fromChange: -999,
fromCountIndex: -999,
checkChange: [],
changeArr: [],
@@ -488,17 +489,37 @@ export default {
});
},
handleCheckChange(data, checked, indeterminate, row, index) { // 处理勾选
+ // console.log(this.fromChange)
+ // console.log(row.operationIds)
+ // console.log(checked)
+ // console.log(this.count)
+ // if(this.fromChange === row.operationIds) {
+ // this.count++
+ // }else {
+ // this.fromChange = row.operationIds
+ // }
+ // if(this.count === 2 || this.count === 0) {
+ // this.checkChange.splice(index, 1, false)
+ // this.count = 0;
+ // }else {
+ // this.checkChange.splice(index, 1, true)
+ // }
+ // if(this.fromChange === row.operationIds) {
+ // this.count++
+ // this.checkChange.splice(index, 1, checked)
+ // }else {
+ // this.checkChange.splice(index, 1, true)
+ // this.fromChange = row.operationIds
+ // }
this.changeArr.push(checked)
+ console.log(this.changeArr)
if(this.changeArr.length === 4) {
- if(this.changeArr[0] && this.changeArr[2]) {
- this.checkChange.splice(index, 1, true)
- }else {
- this.checkChange.splice(index, 1, false)
- }
- this.changeArr.splice(0, 4)
- }else {
+ this.checkChange.splice(index, 1, this.changeArr[2])
+ this.changeArr.splice(0, this.changeArr.length)
+ }else if(this.changeArr.length === 2) {
this.checkChange.splice(index, 1, true)
}
+
let divTree = '#divTree'+index;
let dom = document.querySelector(divTree)
let depTree = '#depTree'+index;
@@ -523,6 +544,15 @@ export default {
this.currentNodeData = {};
this.$refs[`tree-${index}`].setCheckedNodes([data]);
}
+ let divTree = '#divTree'+index;
+ let dom = document.querySelector(divTree)
+ let depTree = '#depTree'+index;
+ let dom1 = document.querySelector(depTree)
+ let nodeHight =26
+ dom.scrollTo(0, 26)
+ dom1.style.height = (data.number * nodeHight) + "px"
+ let contHeight=(data.number * nodeHight)//总高度,盒子高度的一半
+ dom.scrollTo(0, contHeight)
}
},
getTreeData() { // 获取树结构数据
@@ -530,7 +560,6 @@ export default {
if (res.status == 200 && res.list.length>0) {
if (res.list.length>0) {
this.treeData = this.toTreeId(res.list, res.list[0].parentId);
- console.log(this.treeData)
if (this.$route.query.lcId) {
this.lcId = this.$route.query.lcId;
this.getInfoData(this.$route.query.lcId);
@@ -618,7 +647,7 @@ export default {
id: "",
lcId: i.lcId,
itemId:'',
- type: i.type ? i.type : "",
+ type: i.type ? i.type : "7",
operationIds: i.operationIds,
resultOperation: i.resultOperation,
ruleOperation: i.ruleOperation