From 25cd61dd24ef10b36534344e426ebef404972843 Mon Sep 17 00:00:00 2001 From: ashish-egov <137176738+ashish-egov@users.noreply.github.com> Date: Wed, 24 Jul 2024 17:28:24 +0530 Subject: [PATCH] Update processTrackUtils.ts --- .../project-factory/src/server/utils/processTrackUtils.ts | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/utilities/project-factory/src/server/utils/processTrackUtils.ts b/utilities/project-factory/src/server/utils/processTrackUtils.ts index 39f5c20e18e..3451e632fb9 100644 --- a/utilities/project-factory/src/server/utils/processTrackUtils.ts +++ b/utilities/project-factory/src/server/utils/processTrackUtils.ts @@ -2,7 +2,7 @@ import config from './../config'; import { produceModifiedMessages } from '../kafka/Listener'; import { v4 as uuidv4 } from 'uuid'; import { executeQuery } from './db'; -import { processTrackStatuses, processTrackTypes } from '../config/constants'; +import { processTrackForUi, processTrackStatuses, processTrackTypes } from '../config/constants'; import { logger } from './logger'; async function getProcessDetails(id: string, type?: string): Promise { @@ -32,12 +32,13 @@ async function getProcessDetails(id: string, type?: string): Promise { logger.info('No process details found'); return []; } - + const uiSet = new Set(processTrackForUi.map((item: any) => item)); return queryResponse.rows.map((result: any) => ({ id: result.id, campaignId: result.campaignid, type: result.type, status: result.status, + showInUi: uiSet.has(result.type), details: result.details, additionalDetails: result.additionaldetails, createdTime: parseInt(result.createdtime, 10),