From df7886a44ad0441a185182317e0b5c5d9b2c1aba Mon Sep 17 00:00:00 2001 From: Armand Welsh Date: Wed, 4 Sep 2024 20:19:16 -0700 Subject: [PATCH] Update hubigraph_time_graph.groovy Change parser to properly handle attribute names with _ in the name --- hubigraph_time_graph.groovy | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/hubigraph_time_graph.groovy b/hubigraph_time_graph.groovy index b407b4a..4791888 100644 --- a/hubigraph_time_graph.groovy +++ b/hubigraph_time_graph.groovy @@ -1667,7 +1667,8 @@ def getOverlay(){ val.each{ str-> splitStr = str.split('_'); deviceId = splitStr[1]; - attribute = splitStr[2]; + attribute = str[(splitStr[0]?.size() + splitStr[1]?.size() + 2)-str.size()..-1] + sensor = sensors.find{ it.id == deviceId } ;