feat(map): render classified unit identity aspects
This commit is contained in:
@@ -12,7 +12,7 @@ const FIELD_KEYS = new Set([
|
||||
const SOURCES = new Set(["fact", "attribute", "geometry", "context"]);
|
||||
const FORMATS = new Set([
|
||||
"text", "number", "timestamp", "boolean", "coordinate",
|
||||
"signal_state", "movement_state", "telemetry_readings",
|
||||
"signal_state", "movement_state", "string_list", "telemetry_readings",
|
||||
]);
|
||||
const DATA_CLASSES = new Set(["operational", "restricted"]);
|
||||
const FACT_FIELDS = new Set(["sourceId", "semanticType", "observedAt", "receivedAt", "presentationStatus"]);
|
||||
@@ -98,6 +98,9 @@ function normalizeField(value) {
|
||||
if (format === "telemetry_readings" && (source !== "attribute" || field !== "sensor_readings")) {
|
||||
fail("map_subject_detail_profile_readings_source_invalid");
|
||||
}
|
||||
if (format === "string_list" && source !== "attribute") {
|
||||
fail("map_subject_detail_profile_string_list_source_invalid");
|
||||
}
|
||||
if (format !== "telemetry_readings" && allowedReadingIds.length) {
|
||||
fail("map_subject_detail_profile_reading_ids_not_allowed");
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user