Commit 490d09a8 by zhangzhijie

小案类别改为树结构,点击细案类别会自动选中小案类别

parent 0fdc9a27
......@@ -486,7 +486,7 @@
node-key="id"
:data="zaData"
:props="defaultProps"
default-expand-all
:filter-node-method="filterNode1"
ref="tree1"
@node-click="zaHandleNodeClick"
......@@ -529,7 +529,7 @@
node-key="id"
:data="xaData"
:props="defaultProps"
default-expand-all
:filter-node-method="filterNode"
ref="tree2"
@node-click="xaHandleNodeClick"
......@@ -1087,7 +1087,7 @@ export default {
},
submitBz() {
if (this.ajzlbList.indexOf(this.ajzlb) >= 0 && (this.parentLb.id == null || this.parentLb.id == "") && this.laData.length > 0) {
this.$message.error("请标注小案类别后再完成标注");
this.$message.error("请标注具体小案类别后再完成标注");
return;
}
// if ((this.parentLb.id == null || this.parentLb.id == "") && this.laData.length > 0) {
......@@ -1344,7 +1344,7 @@ export default {
}).then((res) => {
this.xcbh = res.data.rows.xcbh;
//this.xcbhUrl = `${res.data.rows.xckyurl}${res.data.rows.xcbh}`;
this.xcbhUrl = res.data.rows.xckyurl+res.data.rows.xcbh;
this.xcbhUrl = res.data.rows.xckyurl + res.data.rows.xcbh;
this.kydd = res.data.rows.kydd;
this.kysjks = res.data.rows.kysjks;
this.kysjjs = res.data.rows.kysjjs;
......@@ -1583,14 +1583,15 @@ export default {
// });
// },
xaHandleNodeClick(data) {
console.log(data)
this.parentLb.childId = data.id;
// axios.get(`JsonData/CODE_AJXZ.json`).then((response) => {
// if (response.success === true) {
// this.laData = response.data.rows.filter((val) => {
// return val.id == data.parentId;
// });
// }
// });
axios.get(`JsonData/CODE_AJXZ.json`).then((response) => {
if (response.success === true) {
this.laData = response.data.rows.filter((val) => {
return val.parentId == `${this.ajzlb}0000`;
});
}
});
setTimeout(() => {
this.$refs.tree3.setCurrentKey(data.parentId);
}, 50);
......@@ -1598,20 +1599,23 @@ export default {
lzHandleNodeClick(res) {
this.xaData = [];
this.parentLb.childId = "";
this.parentLb.id = res.id;
var laDataData = [];
axios.get(`JsonData/CODE_AJXZ.json`).then((response) => {
if (response.success === true) {
response.data.rows.map((item) => {
if (item.parentId == res.id) {
laDataData.push(item);
}
});
if (laDataData.length > 0) {
this.laData = laDataData;
}
}
});
this.parentLb.id = "";
if (res.children.length == 0) {
this.parentLb.id = res.id;
}
//var laDataData = [];
// axios.get(`JsonData/CODE_AJXZ.json`).then((response) => {
// if (response.success === true) {
// response.data.rows.map((item) => {
// if (item.parentId == res.id) {
// laDataData.push(item);
// }
// });
// if (laDataData.length > 0) {
// this.laData = laDataData;
// }
// }
// });
axios.get(`JsonData/CODE_AJXLB.json`).then((response) => {
if (response.success === true) {
......@@ -2212,8 +2216,8 @@ export default {
/deep/ .el-tree-node {
white-space: nowrap;
outline: 0;
height: 40px;
line-height: 40px;
//height: 40px;
//line-height: 40px;
}
.titleSpan {
......
......@@ -1572,7 +1572,7 @@ export default {
axios.get(`JsonData/CODE_AJXZ.json`).then((response) => {
if (response.success === true) {
this.laData = response.data.rows.filter((val) => {
return val.id == data.parentId;
return val.parentId == `${this.ajzlb}0000`;
});
}
});
......@@ -1583,20 +1583,23 @@ export default {
lzHandleNodeClick(res) {
this.xaData = [];
this.parentLb.childId = "";
this.parentLb.id = res.id;
var laDataData = [];
axios.get(`JsonData/CODE_AJXZ.json`).then((response) => {
if (response.success === true) {
response.data.rows.map((item) => {
if (item.parentId == res.id) {
laDataData.push(item);
}
});
if (laDataData.length > 0) {
this.laData = laDataData;
}
}
});
this.parentLb.id = "";
if (res.children.length == 0) {
this.parentLb.id = res.id;
}
// var laDataData = [];
// axios.get(`JsonData/CODE_AJXZ.json`).then((response) => {
// if (response.success === true) {
// response.data.rows.map((item) => {
// if (item.parentId == res.id) {
// laDataData.push(item);
// }
// });
// if (laDataData.length > 0) {
// this.laData = laDataData;
// }
// }
// });
axios.get(`JsonData/CODE_AJXLB.json`).then((response) => {
if (response.success === true) {
......@@ -2197,8 +2200,8 @@ export default {
/deep/ .el-tree-node {
white-space: nowrap;
outline: 0;
height: 40px;
line-height: 40px;
//height: 40px;
//line-height: 40px;
}
.titleSpan {
......
......@@ -730,6 +730,8 @@ export default {
},
data() {
return {
ajzlbList: ['05001000', '04000900', '06012400', '05001100', '06012300', '03080700',
'04000300', '06015400', '05000200', '05000300', '05000100', '05000400', '06010300'],
bzztFlag: false,
textarea: "",
dialogVisible: false,
......@@ -1086,15 +1088,14 @@ export default {
//window.open(this.xcbhUrl, "_blank");
},
submitBz() {
if ((this.parentLb.id == null || this.parentLb.id == "") && this.laData.length > 0) {
this.$message.error("请标注小案类别后再完成标注");
return;
}
if ((this.parentLb.childId == null || this.parentLb.childId == "") && this.xaData.length > 0) {
this.$message.error("请标注细案类别后再完成标注");
if (this.ajzlbList.indexOf(this.ajzlb) >= 0 && (this.parentLb.id == null || this.parentLb.id == "") && this.laData.length > 0) {
this.$message.error("请标注具体小案类别后再完成标注");
return;
}
// if ((this.parentLb.childId == null || this.parentLb.childId == "") && this.xaData.length > 0) {
// this.$message.error("请标注细案类别后再完成标注");
// return;
// }
this.$confirm("此操作将进行案件标注, 是否继续?", "提示", {
confirmButtonText: "确定",
cancelButtonText: "取消",
......@@ -1576,7 +1577,7 @@ export default {
axios.get(`JsonData/CODE_AJXZ.json`).then((response) => {
if (response.success === true) {
this.laData = response.data.rows.filter((val) => {
return val.id == data.parentId;
return val.parentId == `${this.ajzlb}0000`;
});
}
});
......@@ -1587,20 +1588,23 @@ export default {
lzHandleNodeClick(res) {
this.xaData = [];
this.parentLb.childId = "";
this.parentLb.id = res.id;
var laDataData = [];
axios.get(`JsonData/CODE_AJXZ.json`).then((response) => {
if (response.success === true) {
response.data.rows.map((item) => {
if (item.parentId == res.id) {
laDataData.push(item);
}
});
if (laDataData.length > 0) {
this.laData = laDataData;
}
}
});
this.parentLb.id = "";
if (res.children.length == 0) {
this.parentLb.id = res.id;
}
// var laDataData = [];
// axios.get(`JsonData/CODE_AJXZ.json`).then((response) => {
// if (response.success === true) {
// response.data.rows.map((item) => {
// if (item.parentId == res.id) {
// laDataData.push(item);
// }
// });
// if (laDataData.length > 0) {
// this.laData = laDataData;
// }
// }
// });
axios.get(`JsonData/CODE_AJXLB.json`).then((response) => {
if (response.success === true) {
......@@ -2201,8 +2205,8 @@ export default {
/deep/ .el-tree-node {
white-space: nowrap;
outline: 0;
height: 40px;
line-height: 40px;
//height: 40px;
//line-height: 40px;
}
.titleSpan {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment