mirror of
https://github.com/DI0IK/homepage-plus.git
synced 2025-07-07 22:28:48 +00:00
Enhancement: multiple widgets per service (#4338)
This commit is contained in:
parent
385511f773
commit
907abee1aa
46 changed files with 210 additions and 169 deletions
|
@ -34,10 +34,10 @@ async function login(loginUrl, username, password, service) {
|
|||
}
|
||||
|
||||
export default async function beszelProxyHandler(req, res) {
|
||||
const { group, service, endpoint } = req.query;
|
||||
const { group, service, endpoint, index } = req.query;
|
||||
|
||||
if (group && service) {
|
||||
const widget = await getServiceWidget(group, service);
|
||||
const widget = await getServiceWidget(group, service, index);
|
||||
|
||||
if (!widgets?.[widget.type]?.api) {
|
||||
return res.status(403).json({ error: "Service does not support API calls" });
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue