mirror of
https://github.com/fosrl/pangolin.git
synced 2026-03-09 12:16:36 +00:00
✨serverside filter+paginate client resources table
This commit is contained in:
@@ -247,7 +247,7 @@ export async function listSites(
|
||||
const baseQuery = querySitesBase().where(conditions);
|
||||
|
||||
// we need to add `as` so that drizzle filters the result as a subquery
|
||||
const countQuery = db.$count(baseQuery.as("filtered_sites"));
|
||||
const countQuery = db.$count(querySitesBase().where(conditions));
|
||||
|
||||
const siteListQuery = baseQuery
|
||||
.limit(pageSize)
|
||||
|
||||
Reference in New Issue
Block a user