From fb0c8929b7b38317ef0841f14c0426d85352e39d Mon Sep 17 00:00:00 2001 From: Carlos Date: Thu, 5 Oct 2023 09:09:07 -0500 Subject: [PATCH] change to leftJoin on estimatedMatchingTable --- src/repositories/projectRepository.ts | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/repositories/projectRepository.ts b/src/repositories/projectRepository.ts index 3c33d4405..23b9653ea 100644 --- a/src/repositories/projectRepository.ts +++ b/src/repositories/projectRepository.ts @@ -97,12 +97,12 @@ export const filterProjectsQuery = (params: FilterProjectQueryInputParams) => { `project.statusId = ${ProjStatus.active} AND project.reviewStatus = :reviewStatus`, { reviewStatus: ReviewStatus.Listed }, ); - if (qfRoundId) { + if (qfRoundId || activeQfRoundId) { query.innerJoinAndSelect( 'project.qfRounds', 'qf_rounds', 'qf_rounds.id = :qfRoundId', - { qfRoundId }, + { qfRoundId: qfRoundId ? qfRoundId : activeQfRoundId }, ); } if (!sortingBy || sortingBy === SortingField.InstantBoosting) { @@ -168,7 +168,7 @@ export const filterProjectsQuery = (params: FilterProjectQueryInputParams) => { case SortingField.ActiveQfRoundRaisedFunds: if (activeQfRoundId) { query - .innerJoin( + .leftJoin( 'project.projectEstimatedMatchingView', 'projectEstimatedMatchingView', )