Browse Source

修复雷达显示

master
DIAMOND 1 year ago
parent
commit
a6de3afdb8
  1. 31
      src/views/earthMap/edit/EarthComp.vue

31
src/views/earthMap/edit/EarthComp.vue

@ -1694,11 +1694,11 @@
},
};
if (item.labelAttr == 4) {
console.log("雷达",item);
// console.log("",item);
that.statusByNodeId.set(item.id, 1);
that.addLabelNodeToTree(item, models, objConfig3, type);
} else {
console.log("微波",item);
// console.log("",item);
that.statusByNodeId.set(item.id, -10);
that.addLabelNodeToTree(item, models, objConfig3, type);
const device = that.hostDeviceMapById.get(data.deviceId);
@ -1713,6 +1713,7 @@
addLabelNodeToTree(item, models, objConfig3, type) {
const that = this;
//
if (item.labelAttr == 10) {
if (type == 2) {
let childs1 = models.children;
@ -1729,7 +1730,30 @@
let childs2 = parentNode.children;
childs2[2].children.push(objConfig3);
}
} else if (item.labelAttr == 4) {
}
//
else if(item.labelAttr == 4){
if (type == 2) {
let childs1 = models.children;
for (const child of childs1) {
if ('node_' + item.lineId == child.ref) {
child.children[1].children.push(objConfig3);
}
}
} else {
const parentNode = that.nodeConfigByRef.get('node_' + item.lineId);
if (!parentNode) {
return;
}
let childs2 = parentNode.children;
childs2[1].children.push(objConfig3);
}
}
//
else if (item.labelAttr == 4) {
console.log("leida");
if (type == 2) {
let childs3 = models.children;
for (const child of childs3) {
@ -1741,6 +1765,7 @@
}
} else {
const parentNode1 = that.nodeConfigByRef.get('nodeSecondary_' + item.lineId);
// console.log("nodeSecondary_",parentNode1);
if (!parentNode1) {
return;
}

Loading…
Cancel
Save