VictorRobellini / pfSense-Dashboard

A functional and useful dashboard for pfSense that utilizes influxdb, grafana and telegraf
669 stars 184 forks source link

Added status_code numeric field #50

Closed FreeWillyB closed 2 years ago

FreeWillyB commented 2 years ago

Since Grafana only uses numbers for threshold formatting, I've added a "status code" to the GW status. This allows you to do conditional formatting for the GW to easily display wither it's up or down. I haven't made any changes to the map itself since my use case is rather different from the default, but essentially what I'm doing is adding a value mapping for 0, 1, and 2 and then creating overrides for that field to set the background color based on the predetermined thresholds.

New status codes are 0=online, 1=down, and 2=unavailable.

VictorRobellini commented 2 years ago

Thanks, this is a better implementation.