feat(scada): align map asset fields

This commit is contained in:
2026-07-15 18:30:12 +08:00
parent 16ecb69d00
commit 055335e404
11 changed files with 153 additions and 71 deletions
+9 -10
View File
@@ -61,25 +61,24 @@ describe("drainage feature adapter", () => {
);
});
it("uses the promoted SCADA point id for feature-state interactions", () => {
it("uses the promoted SCADA id for feature-state interactions", () => {
const detail = toDetailFeature({
id: "aaedc54a-e5b4-5791-b729-4b7e838a8d00",
id: "4bfa834b-cbbb-5f35-9523-7487ac021ed2",
sourceLayer: SOURCE_LAYERS.scada,
properties: {
id: "4bfa834b-cbbb-5f35-9523-7487ac021ed2",
point_id: "aaedc54a-e5b4-5791-b729-4b7e838a8d00",
point_external_id: "36455",
point_name: "DY22东市南街环城南路西段交叉口",
device_external_id: "26825171",
device_type_name: "2代水质仪"
scada_id: "4bfa834b-cbbb-5f35-9523-7487ac021ed2",
site_external_id: "36455",
name: "DY22东市南街环城南路西段交叉口",
external_id: "26825171",
kind: "water_quality"
}
} as unknown as MapGeoJSONFeature);
expect(detail).toMatchObject({
id: "aaedc54a-e5b4-5791-b729-4b7e838a8d00",
id: "4bfa834b-cbbb-5f35-9523-7487ac021ed2",
layer: "scada",
title: "DY22东市南街环城南路西段交叉口",
subtitle: "2代水质仪 · 设备 26825171"
subtitle: "water_quality · 设备 26825171"
});
});
});