Update powerwall.sh

This commit is contained in:
2023-08-20 12:40:18 -05:00
parent 4efaf0d97b
commit 0f66548ada

View File

@@ -137,7 +137,7 @@ AVERAGETEMP(){
if [ "${PW_SENSOR_TYPE[${SENSORa}]}" == "esxi" ]; then
entityid=($(${mysql_conn} -e "SELECT id FROM servermonitor.entities WHERE BINARY name='${3}' AND sensorid='${sensorid}'"))
entityid=${entityid[1]}
echo "HERE: ${3} - ${entityid}"
# echo "HERE: ${3} - ${entityid}"
WHERE="sensorid=${sensorid} AND entity=${entityid}"
else
WHERE="sensorid=${sensorid}"
@@ -400,7 +400,6 @@ DAILYTEMP(){
fi
if [ "${PW_SENSOR_TYPE[${SENSORa}]}" == "esxi" ]; then
echo "HERE1: ${PW_SENSOR_ID[${SENSORa}]} 1 ${vSENSOR// /_}"
average1=$(AVERAGETEMP ${PW_SENSOR_ID[${SENSORa}]} 1 ${vSENSOR// /_})
# average7=$(AVERAGETEMP ${PW_SENSOR_ID[$SENSOR]} 7 ${vSENSOR// /_})
else