逻辑区段调整
This commit is contained in:
parent
d4bc0f6648
commit
dbd01d71a3
@ -78,13 +78,11 @@ export class LogicSectionDraw extends GraphicDrawAssistant<
|
|||||||
AxleCountingSection.Type
|
AxleCountingSection.Type
|
||||||
);
|
);
|
||||||
axleCountingSections.forEach((axleCountingSection) => {
|
axleCountingSections.forEach((axleCountingSection) => {
|
||||||
if (map.has(`${axleCountingSection.id}`)) {
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
const turnoutPosRef = axleCountingSection.datas.turnoutPosRef;
|
const turnoutPosRef = axleCountingSection.datas.turnoutPosRef;
|
||||||
if (turnoutPosRef.length > 0) {
|
if (turnoutPosRef.length > 0) {
|
||||||
turnoutPosRef.forEach((turnout) => {
|
turnoutPosRef.forEach((turnout) => {
|
||||||
if (turnout.position == 1) {
|
if (turnout.position == 1 && !map.has(`${turnout.id}`)) {
|
||||||
|
map.set(`${turnout.id}`, 1);
|
||||||
const t = this.app.queryStore.queryById(turnout.id) as Turnout;
|
const t = this.app.queryStore.queryById(turnout.id) as Turnout;
|
||||||
const data = new LogicSectionData();
|
const data = new LogicSectionData();
|
||||||
data.points = [
|
data.points = [
|
||||||
@ -96,10 +94,13 @@ export class LogicSectionDraw extends GraphicDrawAssistant<
|
|||||||
}
|
}
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
if (!map.has(`${axleCountingSection.id}`)) {
|
||||||
|
map.set(`${axleCountingSection.id}`, 1);
|
||||||
const data = new LogicSectionData();
|
const data = new LogicSectionData();
|
||||||
data.points = axleCountingSection.datas.points;
|
data.points = axleCountingSection.datas.points;
|
||||||
data.axleSectionId = axleCountingSection.id;
|
data.axleSectionId = axleCountingSection.id;
|
||||||
this.draw(data);
|
this.draw(data);
|
||||||
|
}
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user