Skip to content

Commit

Permalink
Resolve double counting commitments
Browse files Browse the repository at this point in the history
Filter commitment funds to only the "totals" when returning a single capital project

closes #357
  • Loading branch information
TangoYankee committed Aug 2, 2024
1 parent 9e4f074 commit 37eee07
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions src/capital-project/capital-project.repository.ts
Original file line number Diff line number Diff line change
Expand Up @@ -93,6 +93,7 @@ export class CapitalProjectRepository {
and(
eq(capitalProject.managingCode, managingCode),
eq(capitalProject.id, capitalProjectId),
eq(capitalCommitmentFund.category, "total"),
),
)
.groupBy(capitalProject.managingCode, capitalProject.id)
Expand Down

0 comments on commit 37eee07

Please sign in to comment.