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