Feature: Prometheus Metric service widget (#4269)

Co-authored-by: shamoon <4887959+shamoon@users.noreply.github.com>
This commit is contained in:
Felix Cornelius 2024-11-12 01:42:14 +01:00 committed by GitHub
parent 794ec127cd
commit e938c3ac1e
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
8 changed files with 211 additions and 1 deletions

View file

@ -418,7 +418,7 @@ export function cleanServiceGroups(groups) {
pointsLimit,
diskUnits,
// glances, customapi, iframe
// glances, customapi, iframe, prometheusmetric
refreshInterval,
// hdhomerun
@ -461,6 +461,9 @@ export function cleanServiceGroups(groups) {
// opnsense, pfsense
wan,
// prometheusmetric
metrics,
// proxmox
node,
@ -646,6 +649,10 @@ export function cleanServiceGroups(groups) {
if (type === "vikunja") {
if (enableTaskList !== undefined) cleanedService.widget.enableTaskList = !!enableTaskList;
}
if (type === "prometheusmetric") {
if (metrics) cleanedService.widget.metrics = metrics;
if (refreshInterval) cleanedService.widget.refreshInterval = refreshInterval;
}
}
return cleanedService;