int批处理
This commit is contained in:
parent
144fedf110
commit
7a069b955e
@ -396,6 +396,86 @@ export function saveCommonDrawDatas(app: IDrawApp) {
|
||||
);
|
||||
}
|
||||
});
|
||||
storage.Platforms.forEach((item) => {
|
||||
item.common.newId = +item.common.id;
|
||||
item.newrefStationId = +item.refStationId;
|
||||
item.newrefSectionId = +item.refSectionId;
|
||||
});
|
||||
storage.stations.forEach((item) => {
|
||||
item.common.newId = +item.common.id;
|
||||
item.newmanageStations = item.manageStations.map((item) => +item);
|
||||
});
|
||||
storage.screenDoors.forEach((item) => {
|
||||
item.common.newId = +item.common.id;
|
||||
item.newRefPlatformId = +item.refPlatformId;
|
||||
});
|
||||
storage.turnouts.forEach((item) => {
|
||||
item.common.newId = +item.common.id;
|
||||
item.newcentralizedStations = item.centralizedStations.map((item) => +item);
|
||||
item.newpaTrackSectionId = +item.paTrackSectionId;
|
||||
item.newpbTrackSectionId = +item.pbTrackSectionId;
|
||||
item.newpcTrackSectionId = +item.pcTrackSectionId;
|
||||
});
|
||||
storage.signals.forEach((item) => {
|
||||
item.common.newId = +item.common.id;
|
||||
console.log(item.centralizedStations);
|
||||
|
||||
item.newcentralizedStations = item.centralizedStations.map((item) => +item);
|
||||
});
|
||||
storage.section.forEach((item) => {
|
||||
item.common.newId = +item.common.id;
|
||||
item.newcentralizedStations = item.centralizedStations.map((item) => +item);
|
||||
item.newaxleCountings = item.axleCountings.map((item) => +item);
|
||||
item.newtrackSectionId = +item.trackSectionId;
|
||||
});
|
||||
storage.trainWindows.forEach((item) => {
|
||||
item.common.newId = +item.common.id;
|
||||
});
|
||||
storage.axleCountings.forEach((item) => {
|
||||
item.common.newId = +item.common.id;
|
||||
item.newcentralizedStations = item.centralizedStations.map((item) => +item);
|
||||
});
|
||||
storage.separators.forEach((item) => {
|
||||
item.common.newId = +item.common.id;
|
||||
});
|
||||
storage.stopPositions.forEach((item) => {
|
||||
item.common.newId = +item.common.id;
|
||||
});
|
||||
storage.spksSwitchs.forEach((item) => {
|
||||
item.common.newId = +item.common.id;
|
||||
item.newrefSections = item.refSections.map((item) => +item);
|
||||
item.newrefStand = +item.refStand;
|
||||
});
|
||||
storage.gateBoxs.forEach((item) => {
|
||||
item.common.newId = +item.common.id;
|
||||
item.newrefScreenDoor = +item.refScreenDoor;
|
||||
});
|
||||
storage.transponders.forEach((item) => {
|
||||
item.common.newId = +item.common.id;
|
||||
item.newcentralizedStations = item.centralizedStations.map((item) => +item);
|
||||
});
|
||||
storage.slopeKiloMarker.forEach((item) => {
|
||||
item.common.newId = +item.common.id;
|
||||
});
|
||||
storage.slopes.forEach((item) => {
|
||||
item.common.newId = +item.common.id;
|
||||
item.newrefDeviceId = item.refDeviceId.map((item) => +item);
|
||||
});
|
||||
storage.curvatureKiloMarker.forEach((item) => {
|
||||
item.common.newId = +item.common.id;
|
||||
});
|
||||
storage.curvatures.forEach((item) => {
|
||||
item.common.newId = +item.common.id;
|
||||
item.newrefDeviceId = item.refDeviceId.map((item) => +item);
|
||||
});
|
||||
storage.polygons.forEach((item) => {
|
||||
item.common.newId = +item.common.id;
|
||||
});
|
||||
storage.concentrationDividingLines.forEach((item) => {
|
||||
item.common.newId = +item.common.id;
|
||||
item.newrefLeftStationId = +item.refLeftStationId;
|
||||
item.newrefRightStationId = +item.refRightStationId;
|
||||
});
|
||||
storage.UniqueIdPrefix = UniqueIdPrefix;
|
||||
storage.screenDoorConfig = screenDoorConfig;
|
||||
storage.generateAxleCountingConfig = generateAxleCountingConfig;
|
||||
@ -403,6 +483,20 @@ export function saveCommonDrawDatas(app: IDrawApp) {
|
||||
storage.sectionCodePointList = sectionCodePointList;
|
||||
storage.otherLineList = otherLineList;
|
||||
storage.stationRelateDeviceList = refDevicesList;
|
||||
if (storage.generateAxleCountingConfig?.bbConnect) {
|
||||
storage.generateAxleCountingConfig.newbbConnect =
|
||||
storage.generateAxleCountingConfig.bbConnect.map((item) => +item);
|
||||
}
|
||||
if (storage.generateAxleCountingConfig?.noGenerateGroup) {
|
||||
storage.generateAxleCountingConfig.newnoGenerateGroup =
|
||||
storage.generateAxleCountingConfig?.noGenerateGroup.map((item) => +item);
|
||||
}
|
||||
storage.sectionCodePointList.forEach((item) => {
|
||||
item.newsectionIds = item.sectionIds.map((item) => +item);
|
||||
});
|
||||
storage.otherLineList.forEach((item) => {
|
||||
item.newids = item.ids.map((item) => +item);
|
||||
});
|
||||
return storage;
|
||||
}
|
||||
|
||||
|
@ -184,6 +184,23 @@ export function saveJkDrawDatas(app: IDrawApp) {
|
||||
storage.esbButtons.push((esbButtonData as EsbButtonData).data);
|
||||
}
|
||||
});
|
||||
storage.sectionLinks.forEach((item) => {
|
||||
item.common.newId = +item.common.id;
|
||||
item.aSimRef.newid = item.aSimRef.id;
|
||||
item.bSimRef.newid = item.bSimRef.id;
|
||||
});
|
||||
storage.axleCountingSections.forEach((item) => {
|
||||
item.common.newId = +item.common.id;
|
||||
});
|
||||
storage.logicSections.forEach((item) => {
|
||||
item.common.newId = +item.common.id;
|
||||
item.newaxleSectionId = +item.axleSectionId;
|
||||
item.newturnoutId = +item.turnoutId;
|
||||
});
|
||||
storage.esbButtons.forEach((item) => {
|
||||
item.common.newId = +item.common.id;
|
||||
});
|
||||
|
||||
const base64 = fromUint8Array(storage.serialize());
|
||||
return base64;
|
||||
}
|
||||
|
@ -153,6 +153,17 @@ export function saveThDrawDatas(app: IDrawApp) {
|
||||
storage.esbButtons.push((esbButtonData as EsbButtonData).data);
|
||||
}
|
||||
});
|
||||
storage.trackSections.forEach((item) => {
|
||||
item.common.newId = +item.common.id;
|
||||
item.newtrackLogicSection = item.trackLogicSection.map((item) => +item);
|
||||
});
|
||||
storage.trackLogicSections.forEach((item) => {
|
||||
item.common.newId = +item.common.id;
|
||||
});
|
||||
storage.esbButtons.forEach((item) => {
|
||||
item.common.newId = +item.common.id;
|
||||
item.newrefStand = +item.refStand;
|
||||
});
|
||||
const base64 = fromUint8Array(storage.serialize());
|
||||
return base64;
|
||||
}
|
||||
|
@ -215,6 +215,27 @@ export function saveZdwxDrawDatas(app: IDrawApp) {
|
||||
);
|
||||
}
|
||||
});
|
||||
storage.trackSections.forEach((item) => {
|
||||
item.common.newId = +item.common.id;
|
||||
});
|
||||
storage.trackLogicSections.forEach((item) => {
|
||||
item.common.newId = +item.common.id;
|
||||
});
|
||||
storage.beacons.forEach((item) => {
|
||||
item.common.newId = +item.common.id;
|
||||
});
|
||||
storage.esbButtons.forEach((item) => {
|
||||
item.common.newId = +item.common.id;
|
||||
item.newrefStand = +item.refStand;
|
||||
});
|
||||
storage.departureTimers.forEach((item) => {
|
||||
item.common.newId = +item.common.id;
|
||||
item.newrefStand = +item.refStand;
|
||||
});
|
||||
storage.autoReturnBoxs.forEach((item) => {
|
||||
item.common.newId = +item.common.id;
|
||||
item.newrefStand = +item.refStand;
|
||||
});
|
||||
const base64 = fromUint8Array(storage.serialize());
|
||||
return base64;
|
||||
}
|
||||
|
File diff suppressed because it is too large
Load Diff
Loading…
Reference in New Issue
Block a user