Commit ad9c9750 by liuwange1

巡检

parent 55d2b4b5
......@@ -145,7 +145,7 @@ export default {
osc: 11,
oscName: "/EZ_AF",
roadList: [],
roadActiveIndex: 0,
roadActiveIndex: -1,
listL: [],
listR: [],
activeIndex: 0,
......@@ -194,11 +194,26 @@ export default {
});
},
roadClick(index) {
this.roadActiveIndex = index;
this.$axios.post("/osc/sendInt", {
arg: this.roadList[index].lineId,
name: "/XJ_LINE_ID",
});
if (index == this.roadActiveIndex) {
this.$axios.post("/osc/sendInt", {
arg: false,
name: "/JKYL",
});
this.roadActiveIndex = -1;
} else {
this.roadActiveIndex = index;
this.$axios
.post("/osc/sendInt", {
arg: true,
name: "/JKYL",
})
.then(() => {
this.$axios.post("/osc/sendInt", {
arg: this.roadList[index].lineId,
name: "/XJ_LINE_ID",
});
});
}
},
LYchange(e) {
this.activeIndex = e.target.selectedIndex;
......
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 sign in to comment