微调
This commit is contained in:
parent
7a8b5c2eb4
commit
8c639ce242
@ -81,7 +81,6 @@ export class AxleCountingDraw extends GraphicDrawAssistant<
|
|||||||
refPort: TurnoutPort | SectionPort
|
refPort: TurnoutPort | SectionPort
|
||||||
) {
|
) {
|
||||||
const generateAxleCountingConfig = loadGenerateAxleCountingConfig();
|
const generateAxleCountingConfig = loadGenerateAxleCountingConfig();
|
||||||
let hasNoGenerateGroup = false;
|
|
||||||
if (generateAxleCountingConfig?.noGenerateGroup !== undefined) {
|
if (generateAxleCountingConfig?.noGenerateGroup !== undefined) {
|
||||||
const noGenerateGroup = generateAxleCountingConfig.noGenerateGroup;
|
const noGenerateGroup = generateAxleCountingConfig.noGenerateGroup;
|
||||||
for (let i = 0; i < noGenerateGroup.length; i++) {
|
for (let i = 0; i < noGenerateGroup.length; i++) {
|
||||||
@ -90,15 +89,12 @@ export class AxleCountingDraw extends GraphicDrawAssistant<
|
|||||||
((i % 2 == 0 && refGraphic.id == noGenerateGroup[i + 1]) ||
|
((i % 2 == 0 && refGraphic.id == noGenerateGroup[i + 1]) ||
|
||||||
(i % 2 == 1 && refGraphic.id == noGenerateGroup[i - 1]))
|
(i % 2 == 1 && refGraphic.id == noGenerateGroup[i - 1]))
|
||||||
) {
|
) {
|
||||||
hasNoGenerateGroup = true;
|
map.set(`${graphic.id}-${port}`, 1);
|
||||||
|
map.set(`${refGraphic.id}-${refPort}`, 1);
|
||||||
|
return;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if (hasNoGenerateGroup) {
|
|
||||||
map.set(`${graphic.id}-${port}`, 1);
|
|
||||||
map.set(`${refGraphic.id}-${refPort}`, 1);
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
if (
|
if (
|
||||||
graphic.type == 'Turnout' &&
|
graphic.type == 'Turnout' &&
|
||||||
reftype == 'Turnout' &&
|
reftype == 'Turnout' &&
|
||||||
|
Loading…
Reference in New Issue
Block a user