diff --git a/public/services/FindingsService.ts b/public/services/FindingsService.ts index 30674500..4bb671c0 100644 --- a/public/services/FindingsService.ts +++ b/public/services/FindingsService.ts @@ -19,8 +19,8 @@ export default class FindingsService { getFindings = async ( detectorParams: GetFindingsParams ): Promise> => { - const findingIds = detectorParams.findingIds - ? JSON.stringify(detectorParams.findingIds) + const findingIds = getFindingsParams.findingIds + ? getFindingsParams.findingIds.join(',') : undefined; const query = { sortOrder: 'desc', diff --git a/server/routes/FindingsRoutes.ts b/server/routes/FindingsRoutes.ts index 0bb659a4..d5ddf1f8 100644 --- a/server/routes/FindingsRoutes.ts +++ b/server/routes/FindingsRoutes.ts @@ -25,7 +25,9 @@ export function setupFindingsRoutes(services: NodeServices, router: IRouter) { detectionType: schema.maybe(schema.string()), severity: schema.maybe(schema.string()), searchString: schema.maybe(schema.string()), - findingIds: schema.maybe(schema.arrayOf(schema.string())), + findingIds: schema.maybe(schema.string()), + startTime: schema.maybe(schema.number()), + endTime: schema.maybe(schema.number()) }), }, },