fix(scada): preserve observation fields in chart evidence
This commit is contained in:
@@ -394,6 +394,9 @@ async def execute_query(
|
||||
if hasattr(args, "field") and args.field not in units:
|
||||
gaps.append(f"Unit metadata is unavailable for field {args.field}")
|
||||
else:
|
||||
# Keep the selected field in durable evidence; `value` alone cannot
|
||||
# distinguish raw observations from cleaned observations.
|
||||
data = [{**row, args.field: row["value"]} if "value" in row else row for row in data]
|
||||
metadata = [
|
||||
r
|
||||
for device in ids
|
||||
|
||||
Reference in New Issue
Block a user