From 97ac1eec3f0549ef3de01a44bea95ebaf416a64c Mon Sep 17 00:00:00 2001 From: andig Date: Sun, 8 Dec 2024 11:13:06 +0100 Subject: [PATCH] chore: simplify --- templates/definition/meter/fronius-ohmpilot.yaml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/templates/definition/meter/fronius-ohmpilot.yaml b/templates/definition/meter/fronius-ohmpilot.yaml index a287f84e4..4bdf01bb3 100644 --- a/templates/definition/meter/fronius-ohmpilot.yaml +++ b/templates/definition/meter/fronius-ohmpilot.yaml @@ -18,8 +18,8 @@ render: | power: source: http uri: http://{{ .host }}/solar_api/v1/GetPowerFlowRealtimeData.fcgi - jq: if .Body.Data.Smartloads.Ohmpilots."{{ .key }}".P_AC_Total == null then 0 else .Body.Data.Smartloads.Ohmpilots."{{ .key }}".P_AC_Total end + jq: if .Body.Data.Smartloads.Ohmpilots.{{ .key }}.P_AC_Total == null then 0 else .Body.Data.Smartloads.Ohmpilots.{{ .key }}.P_AC_Total end soc: source: http uri: http://{{ .host }}/solar_api/v1/GetPowerFlowRealtimeData.fcgi - jq: if .Body.Data.Smartloads.Ohmpilots."{{ .key }}".Temperature == null then 0 else .Body.Data.Smartloads.Ohmpilots."{{ .key }}".Temperature end + jq: if .Body.Data.Smartloads.Ohmpilots.{{ .key }}.Temperature == null then 0 else .Body.Data.Smartloads.Ohmpilots.{{ .key }}.Temperature end