mirror of
https://github.com/DI0IK/homepage-plus.git
synced 2025-07-10 23:38:46 +00:00
Pihole allow auth, updated API endpoint
This commit is contained in:
parent
de584eae8f
commit
a9429e5335
2 changed files with 7 additions and 7 deletions
|
@ -9,7 +9,7 @@ export default function Component({ service }) {
|
|||
|
||||
const { widget } = service;
|
||||
|
||||
const { data: piholeData, error: piholeError } = useWidgetAPI(widget, "api.php");
|
||||
const { data: piholeData, error: piholeError } = useWidgetAPI(widget, "summaryRaw");
|
||||
|
||||
if (piholeError) {
|
||||
return <Container error={piholeError} />;
|
||||
|
@ -27,9 +27,9 @@ export default function Component({ service }) {
|
|||
|
||||
return (
|
||||
<Container service={service}>
|
||||
<Block label="pihole.queries" value={t("common.number", { value: piholeData.dns_queries_today })} />
|
||||
<Block label="pihole.blocked" value={t("common.number", { value: piholeData.ads_blocked_today })} />
|
||||
<Block label="pihole.gravity" value={t("common.number", { value: piholeData.domains_being_blocked })} />
|
||||
<Block label="pihole.queries" value={t("common.number", { value: parseInt(piholeData.dns_queries_today, 10) })} />
|
||||
<Block label="pihole.blocked" value={t("common.number", { value: parseInt(piholeData.ads_blocked_today, 10) })} />
|
||||
<Block label="pihole.gravity" value={t("common.number", { value: parseInt(piholeData.domains_being_blocked, 10) })} />
|
||||
</Container>
|
||||
);
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue