Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

10049 display wip cav submitted cases #3983

Merged

Conversation

Absolutestunna
Copy link
Contributor

No description provided.

Absolutestunna and others added 30 commits September 11, 2023 13:54
…on counts to be retrieved by one lambda. Update test data
…ountOfOrdersFiledByJudgesInteractor into getCountOfCaseDocumentsFiledByJudgesInteractor, update tests
…urn order and opinion objects, remove references to deleted interactors
…tors. Replace return type for said interactors with new AggregatedEventCodesType
…d judgeNameToDisplayForHeader; cleaned up overloaded JudgeActivityReportFilter types
…-activity-report-JudgeActivityReportFilters-refactor
…b.com/flexion/ef-cms into 10049-judge-activity-report-JudgeActivityReportFilters-refactor
…dgeActivityReportFilters-refactor

10049 judge activity report judge activity report filters refactor
@Absolutestunna Absolutestunna force-pushed the 10049-display-wip-cav-submitted-cases branch from 5554299 to c30424f Compare September 21, 2023 17:48
Comment on lines +42 to +73
const { aggregations: opinionAggregationCount, total: opinionTotal } =
await applicationContext
.getPersistenceGateway()
.fetchEventCodesCountForJudges({
applicationContext,
params: {
documentEventCodes: OPINION_EVENT_CODES_WITH_BENCH_OPINION,
endDate: searchEntity.endDate,
judges: searchEntity.judges,
startDate: searchEntity.startDate,
},
});

const computedAggregatedOpinionEventCodes =
addDocumentTypeToEventCodeAggregation(opinionAggregationCount);

const { aggregations: orderAggregationCount, total: orderTotal } =
await applicationContext
.getPersistenceGateway()
.fetchEventCodesCountForJudges({
applicationContext,
params: {
documentEventCodes: JUDGE_ACTIVITY_REPORT_ORDER_EVENT_CODES,
endDate: searchEntity.endDate,
judges: searchEntity.judges,
startDate: searchEntity.startDate,
},
});

const computedAggregatedOrderEventCodes =
addDocumentTypeToEventCodeAggregation(orderAggregationCount);

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is an improvement by consolidating this into one interactor! 👏

I think we can do better by having the client call the endpoint with the event codes upon which it wants to report. So, it might make two calls for the information it needs; or more calls if sometime in the future we need to support different subsets of event codes. Perhaps other UIs will make use of this.

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

No need to perform this refactor now; I will document it and open up a PR after this is merged.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Agreed!

@@ -1,6 +1,6 @@
import { count } from './searchClient';

export const getCountOfConsolidedCases = async ({
export const getCountOfConsolidatedCases = async ({
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

ty!

@mmarcotte mmarcotte merged commit 8ab7f26 into ustaxcourt:staging Sep 22, 2023
35 checks passed
@jimlerza jimlerza mentioned this pull request Sep 24, 2023
3 tasks
@Absolutestunna Absolutestunna deleted the 10049-display-wip-cav-submitted-cases branch January 22, 2024 22:42
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants