mirror of
https://github.com/fosrl/pangolin.git
synced 2026-09-10 13:06:19 +02:00
Compare commits
3 Commits
ad9289e0c1
..
1.16.1
| Author | SHA1 | Date | |
|---|---|---|---|
| b0cb0e5a99 | |||
| eed87af61d | |||
| daeea8e7ea |
+4
-2
@@ -1,4 +1,5 @@
|
|||||||
FROM node:24-slim AS base
|
# FROM node:24-slim AS base
|
||||||
|
FROM public.ecr.aws/docker/library/node:24-slim AS base
|
||||||
|
|
||||||
WORKDIR /app
|
WORKDIR /app
|
||||||
|
|
||||||
@@ -31,7 +32,8 @@ FROM base AS builder
|
|||||||
|
|
||||||
RUN npm ci --omit=dev
|
RUN npm ci --omit=dev
|
||||||
|
|
||||||
FROM node:24-slim AS runner
|
# FROM node:24-slim AS runner
|
||||||
|
FROM public.ecr.aws/docker/library/node:24-slim AS runner
|
||||||
|
|
||||||
WORKDIR /app
|
WORKDIR /app
|
||||||
|
|
||||||
|
|||||||
@@ -370,7 +370,7 @@ export async function listClients(
|
|||||||
? order === "asc"
|
? order === "asc"
|
||||||
? asc(clients[sort_by])
|
? asc(clients[sort_by])
|
||||||
: desc(clients[sort_by])
|
: desc(clients[sort_by])
|
||||||
: asc(clients.name)
|
: asc(clients.clientId)
|
||||||
);
|
);
|
||||||
|
|
||||||
const [clientsList, totalCount] = await Promise.all([
|
const [clientsList, totalCount] = await Promise.all([
|
||||||
|
|||||||
@@ -429,7 +429,7 @@ export async function listResources(
|
|||||||
? order === "asc"
|
? order === "asc"
|
||||||
? asc(resources[sort_by])
|
? asc(resources[sort_by])
|
||||||
: desc(resources[sort_by])
|
: desc(resources[sort_by])
|
||||||
: asc(resources.name)
|
: asc(resources.resourceId)
|
||||||
),
|
),
|
||||||
countQuery
|
countQuery
|
||||||
]);
|
]);
|
||||||
|
|||||||
@@ -278,7 +278,7 @@ export async function listSites(
|
|||||||
|
|
||||||
// we need to add `as` so that drizzle filters the result as a subquery
|
// we need to add `as` so that drizzle filters the result as a subquery
|
||||||
const countQuery = db.$count(
|
const countQuery = db.$count(
|
||||||
querySitesBase().where(and(...conditions))
|
querySitesBase().where(and(...conditions)).as("filtered_sites")
|
||||||
);
|
);
|
||||||
|
|
||||||
const siteListQuery = baseQuery
|
const siteListQuery = baseQuery
|
||||||
@@ -289,7 +289,7 @@ export async function listSites(
|
|||||||
? order === "asc"
|
? order === "asc"
|
||||||
? asc(sites[sort_by])
|
? asc(sites[sort_by])
|
||||||
: desc(sites[sort_by])
|
: desc(sites[sort_by])
|
||||||
: asc(sites.name)
|
: asc(sites.siteId)
|
||||||
);
|
);
|
||||||
|
|
||||||
const [totalCount, rows] = await Promise.all([
|
const [totalCount, rows] = await Promise.all([
|
||||||
|
|||||||
@@ -193,7 +193,7 @@ export async function listAllSiteResourcesByOrg(
|
|||||||
const baseQuery = querySiteResourcesBase().where(and(...conditions));
|
const baseQuery = querySiteResourcesBase().where(and(...conditions));
|
||||||
|
|
||||||
const countQuery = db.$count(
|
const countQuery = db.$count(
|
||||||
querySiteResourcesBase().where(and(...conditions))
|
querySiteResourcesBase().where(and(...conditions)).as("filtered_site_resources")
|
||||||
);
|
);
|
||||||
|
|
||||||
const [siteResourcesList, totalCount] = await Promise.all([
|
const [siteResourcesList, totalCount] = await Promise.all([
|
||||||
@@ -205,7 +205,7 @@ export async function listAllSiteResourcesByOrg(
|
|||||||
? order === "asc"
|
? order === "asc"
|
||||||
? asc(siteResources[sort_by])
|
? asc(siteResources[sort_by])
|
||||||
: desc(siteResources[sort_by])
|
: desc(siteResources[sort_by])
|
||||||
: asc(siteResources.name)
|
: asc(siteResources.siteResourceId)
|
||||||
),
|
),
|
||||||
countQuery
|
countQuery
|
||||||
]);
|
]);
|
||||||
|
|||||||
@@ -112,7 +112,7 @@ export async function listSiteResources(
|
|||||||
? order === "asc"
|
? order === "asc"
|
||||||
? asc(siteResources[sort_by])
|
? asc(siteResources[sort_by])
|
||||||
: desc(siteResources[sort_by])
|
: desc(siteResources[sort_by])
|
||||||
: asc(siteResources.name)
|
: asc(siteResources.siteResourceId)
|
||||||
)
|
)
|
||||||
.limit(limit)
|
.limit(limit)
|
||||||
.offset(offset);
|
.offset(offset);
|
||||||
|
|||||||
Reference in New Issue
Block a user