mirror of
https://github.com/gethomepage/homepage.git
synced 2026-01-10 10:32:09 +08:00
Feature: Jellystat widget (#5185)
Some checks failed
Crowdin Action / Crowdin Sync (push) Has been cancelled
Docker CI / Linting Checks (push) Has been cancelled
Docker CI / Docker Build & Push (push) Has been cancelled
Repository Maintenance / Stale (push) Has been cancelled
Repository Maintenance / Lock Old Threads (push) Has been cancelled
Repository Maintenance / Close Answered Discussions (push) Has been cancelled
Repository Maintenance / Close Outdated Discussions (push) Has been cancelled
Repository Maintenance / Close Unsupported Feature Requests (push) Has been cancelled
Some checks failed
Crowdin Action / Crowdin Sync (push) Has been cancelled
Docker CI / Linting Checks (push) Has been cancelled
Docker CI / Docker Build & Push (push) Has been cancelled
Repository Maintenance / Stale (push) Has been cancelled
Repository Maintenance / Lock Old Threads (push) Has been cancelled
Repository Maintenance / Close Answered Discussions (push) Has been cancelled
Repository Maintenance / Close Outdated Discussions (push) Has been cancelled
Repository Maintenance / Close Unsupported Feature Requests (push) Has been cancelled
Co-authored-by: shamoon <4887959+shamoon@users.noreply.github.com>
This commit is contained in:
@@ -331,6 +331,9 @@ export function cleanServiceGroups(groups) {
|
||||
referrerPolicy,
|
||||
src,
|
||||
|
||||
// jellystat
|
||||
days,
|
||||
|
||||
// kopia
|
||||
snapshotHost,
|
||||
snapshotPath,
|
||||
@@ -563,6 +566,9 @@ export function cleanServiceGroups(groups) {
|
||||
if (type === "spoolman") {
|
||||
if (spoolIds !== undefined) widget.spoolIds = spoolIds;
|
||||
}
|
||||
if (type === "jellystat") {
|
||||
if (days !== undefined) widget.days = parseInt(days, 10);
|
||||
}
|
||||
return widget;
|
||||
});
|
||||
return cleanedService;
|
||||
|
||||
@@ -65,7 +65,7 @@ export default async function credentialedProxyHandler(req, res, map) {
|
||||
} else if (widget.type === "proxmoxbackupserver") {
|
||||
delete headers["Content-Type"];
|
||||
headers.Authorization = `PBSAPIToken=${widget.username}:${widget.password}`;
|
||||
} else if (widget.type === "autobrr") {
|
||||
} else if (["autobrr", "jellystat"].includes(widget.type)) {
|
||||
headers["X-API-Token"] = `${widget.key}`;
|
||||
} else if (widget.type === "tubearchivist") {
|
||||
headers.Authorization = `Token ${widget.key}`;
|
||||
|
||||
Reference in New Issue
Block a user