Merge branch 'master' of https://git.code.tencent.com/beijing-rtss-test/bj-rtss-client
This commit is contained in:
commit
338d7132b3
@ -230,6 +230,12 @@ export function initDrawApp(dom: HTMLElement): JlDrawApp {
|
|||||||
SectionLink.Type
|
SectionLink.Type
|
||||||
);
|
);
|
||||||
const turnouts = app.queryStore.queryByType<Turnout>(Turnout.Type);
|
const turnouts = app.queryStore.queryByType<Turnout>(Turnout.Type);
|
||||||
|
const disvisibleGraphics = [
|
||||||
|
...sections,
|
||||||
|
...turnouts,
|
||||||
|
...sectionLinks,
|
||||||
|
...axleCountingSections,
|
||||||
|
];
|
||||||
UndoOptions.handler = () => {
|
UndoOptions.handler = () => {
|
||||||
app.opRecord.undo();
|
app.opRecord.undo();
|
||||||
};
|
};
|
||||||
@ -240,9 +246,17 @@ export function initDrawApp(dom: HTMLElement): JlDrawApp {
|
|||||||
app.selectAllGraphics();
|
app.selectAllGraphics();
|
||||||
};
|
};
|
||||||
linkOptions.handler = () => {
|
linkOptions.handler = () => {
|
||||||
console.log(222);
|
disvisibleGraphics.forEach((g) => {
|
||||||
|
g.visible = false;
|
||||||
|
});
|
||||||
|
sectionLinks.forEach((axleCountingSection) => {
|
||||||
|
axleCountingSection.visible = true;
|
||||||
|
});
|
||||||
};
|
};
|
||||||
axleCountingSectionOptions.handler = () => {
|
axleCountingSectionOptions.handler = () => {
|
||||||
|
disvisibleGraphics.forEach((g) => {
|
||||||
|
g.visible = false;
|
||||||
|
});
|
||||||
axleCountingSections.forEach((axleCountingSection) => {
|
axleCountingSections.forEach((axleCountingSection) => {
|
||||||
axleCountingSection.visible = true;
|
axleCountingSection.visible = true;
|
||||||
});
|
});
|
||||||
@ -400,11 +414,17 @@ export async function loadDrawDatas(app: GraphicApp) {
|
|||||||
} else {
|
} else {
|
||||||
app.loadGraphic([]);
|
app.loadGraphic([]);
|
||||||
}
|
}
|
||||||
//隐藏计轴区段
|
//隐藏计轴区段--Link
|
||||||
const axleCountingSections = app.queryStore.queryByType<AxleCountingSection>(
|
const axleCountingSections = app.queryStore.queryByType<AxleCountingSection>(
|
||||||
AxleCountingSection.Type
|
AxleCountingSection.Type
|
||||||
);
|
);
|
||||||
axleCountingSections.forEach((axleCountingSection) => {
|
axleCountingSections.forEach((axleCountingSection) => {
|
||||||
axleCountingSection.visible = false;
|
axleCountingSection.visible = false;
|
||||||
});
|
});
|
||||||
|
const sectionLinks = app.queryStore.queryByType<SectionLink>(
|
||||||
|
SectionLink.Type
|
||||||
|
);
|
||||||
|
sectionLinks.forEach((sectionLink) => {
|
||||||
|
sectionLink.visible = false;
|
||||||
|
});
|
||||||
}
|
}
|
||||||
|
@ -14,7 +14,6 @@ import {
|
|||||||
IAxleCountingData,
|
IAxleCountingData,
|
||||||
AxleCounting,
|
AxleCounting,
|
||||||
AxleCountingTemplate,
|
AxleCountingTemplate,
|
||||||
AxleCountingConsts,
|
|
||||||
} from './AxleCounting';
|
} from './AxleCounting';
|
||||||
import { Section, SectionPort, SectionType } from '../section/Section';
|
import { Section, SectionPort, SectionType } from '../section/Section';
|
||||||
import { Turnout, TurnoutPort } from '../turnout/Turnout';
|
import { Turnout, TurnoutPort } from '../turnout/Turnout';
|
||||||
|
@ -1,7 +1,5 @@
|
|||||||
import { FederatedPointerEvent, IHitArea, IPointData, Point } from 'pixi.js';
|
import { FederatedPointerEvent, IHitArea, IPointData, Point } from 'pixi.js';
|
||||||
import {
|
import {
|
||||||
AbsorbableLine,
|
|
||||||
AbsorbablePosition,
|
|
||||||
GraphicDrawAssistant,
|
GraphicDrawAssistant,
|
||||||
GraphicIdGenerator,
|
GraphicIdGenerator,
|
||||||
GraphicInteractionPlugin,
|
GraphicInteractionPlugin,
|
||||||
|
Loading…
Reference in New Issue
Block a user