mirror of
https://github.com/Dvorinka/Bookra.git
synced 2026-10-28 15:51:15 +00:00
feat(metrics): new-clients KPI and scheduled reminder dispatch
The dashboard promised a new-clients card the API never produced; the metric now counts distinct customer emails whose earliest-ever booking lands in the window, joining the other four KPIs with the same trend comparison. The card grid rebalances for five items. Reminder dispatch also had no trigger — the endpoint existed but nothing called it. A scheduled GitHub Actions workflow now posts to it every 15 minutes using the job-runner key, so reminders actually fire once the two secrets are configured. Generated with [Devin](https://devin.ai) Co-Authored-By: Devin <158243242+devin-ai-integration[bot]@users.noreply.github.com>
This commit is contained in:
1 parent
cdad7875e1
commit
c7172544b8
8 files changed
+93
-20
No files matched your search
@@ -216,6 +216,7 @@ export function DashboardDataProvider(props: { children: any }) {
|
||||
completed: "dashboard.kpi.completed",
|
||||
cancellations: "dashboard.kpi.cancellations",
|
||||
utilization: "dashboard.kpi.utilization",
|
||||
new_clients: "dashboard.kpi.newClients",
|
||||
};
|
||||
const normalizedKpis = createMemo(() => (resolvedSummary()?.kpis ?? []).map((kpi: any) => ({
|
||||
...kpi,
|
||||
|
||||
@@ -37,7 +37,7 @@ function OverviewPage() {
|
||||
</div>
|
||||
|
||||
{/* KPI Cards */}
|
||||
<div class="grid grid-cols-1 sm:grid-cols-2 lg:grid-cols-4 gap-4">
|
||||
<div class="grid grid-cols-1 sm:grid-cols-2 lg:grid-cols-3 xl:grid-cols-5 gap-4">
|
||||
{data.normalizedKpis().map((kpi: any, index: number) => (
|
||||
<KpiCard kpi={kpi} index={index} />
|
||||
))}
|
||||
|
||||
Reference in new issue
Block a user