File tree Expand file tree Collapse file tree
services/libs/data-access-layer/src/project-catalog Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -105,6 +105,25 @@ export async function findProjectCatalogPendingEvaluation(
105105 )
106106}
107107
108+ export async function findProjectCatalogPendingOnboarding (
109+ qx : QueryExecutor ,
110+ options : { limit ?: number ; offset ?: number } = { } ,
111+ ) : Promise < IDbProjectCatalog [ ] > {
112+ const { limit, offset } = options
113+
114+ return qx . select (
115+ `
116+ SELECT ${ prepareSelectColumns ( PROJECT_CATALOG_COLUMNS ) }
117+ FROM "projectCatalog"
118+ WHERE action = 'onboard' AND "onboardedAt" IS NULL
119+ ORDER BY "lfCriticalityScore" DESC NULLS LAST, "createdAt" ASC
120+ ${ limit !== undefined ? 'LIMIT $(limit)' : '' }
121+ ${ offset !== undefined ? 'OFFSET $(offset)' : '' }
122+ ` ,
123+ { limit, offset } ,
124+ )
125+ }
126+
108127export async function countProjectCatalog ( qx : QueryExecutor ) : Promise < number > {
109128 const result = await qx . selectOne (
110129 `
You can’t perform that action at this time.
0 commit comments