From 86cab10c707a513d011054d72532648d124fc178 Mon Sep 17 00:00:00 2001 From: rene Date: Sun, 17 May 2026 14:22:42 +0200 Subject: [PATCH] Fix: sort/filter/expand nach autodate-Feldern wiederhergestellt --- app/src/routes/admin/dashboard/+page.svelte | 4 +++- app/src/routes/admin/logs/+page.svelte | 2 +- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/app/src/routes/admin/dashboard/+page.svelte b/app/src/routes/admin/dashboard/+page.svelte index bd32c37..a7f3312 100644 --- a/app/src/routes/admin/dashboard/+page.svelte +++ b/app/src/routes/admin/dashboard/+page.svelte @@ -24,7 +24,9 @@ const dateStr = today.toISOString().slice(0, 19).replace('T', ' '); const result = await pb.collection('check_logs').getList(1, 50, { - sort: '-id' + filter: `tenant = '${tenantId}' && created >= '${dateStr}'`, + expand: 'station', + sort: '-created' }); logs = result.items; diff --git a/app/src/routes/admin/logs/+page.svelte b/app/src/routes/admin/logs/+page.svelte index c4c1cbb..b975cc5 100644 --- a/app/src/routes/admin/logs/+page.svelte +++ b/app/src/routes/admin/logs/+page.svelte @@ -25,7 +25,7 @@ const result = await pb.collection('check_logs').getList(p, PER_PAGE, { filter: `tenant = '${tenantId}'`, expand: 'station', - sort: '-id' + sort: '-created' }); logs = result.items; page = p;