mirror of
https://github.com/DI0IK/homepage-plus.git
synced 2025-07-09 14:58:47 +00:00
Added custom API widget (#1858)
* Added custom API widget * Rename custom widget to customapi --------- Co-authored-by: shamoon <4887959+shamoon@users.noreply.github.com>
This commit is contained in:
parent
14b886793c
commit
fc7e73eba2
5 changed files with 92 additions and 0 deletions
|
@ -299,6 +299,8 @@ export function cleanServiceGroups(groups) {
|
|||
stream, // mjpeg
|
||||
fit,
|
||||
method, // openmediavault widget
|
||||
mappings, // customapi widget
|
||||
refreshInterval,
|
||||
} = cleanedService.widget;
|
||||
|
||||
let fieldsList = fields;
|
||||
|
@ -372,6 +374,10 @@ export function cleanServiceGroups(groups) {
|
|||
if (type === "openmediavault") {
|
||||
if (method) cleanedService.widget.method = method;
|
||||
}
|
||||
if (type === "customapi") {
|
||||
if (mappings) cleanedService.widget.mappings = mappings;
|
||||
if (refreshInterval) cleanedService.widget.refreshInterval = refreshInterval;
|
||||
}
|
||||
}
|
||||
|
||||
return cleanedService;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue