Skip to content

Commit

Permalink
Merge branch '10491-work-item-refactor' of github.com:flexion/ef-cms …
Browse files Browse the repository at this point in the history
…into 10491-work-item-refactor
  • Loading branch information
pixiwyn committed Oct 8, 2024
2 parents aa5651f + 31eab83 commit c16b3b4
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 5 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@ import {
import { ServerApplicationContext } from '@web-api/applicationContext';
import { UnknownAuthUser } from '@shared/business/entities/authUser/AuthUser';
import { User } from '../../../../../shared/src/business/entities/User';
import { WorkItem } from '@shared/business/entities/WorkItem';
import { addServedStampToDocument } from '@web-api/business/useCases/courtIssuedDocument/addServedStampToDocument';
import { aggregatePartiesForService } from '@shared/business/utilities/aggregatePartiesForService';
import { generateNoticeOfDocketChangePdf } from '@web-api/business/useCaseHelper/noticeOfDocketChange/generateNoticeOfDocketChangePdf';
Expand Down Expand Up @@ -174,7 +175,7 @@ const completeDocketEntryQC = async (
.getUseCaseHelpers()
.updateCaseAutomaticBlock({ applicationContext, caseEntity });

const workItemToUpdate = updatedDocketEntry.workItem;
const workItemToUpdate = updatedDocketEntry.workItem as WorkItem;

Object.assign(workItemToUpdate, {
docketEntry: {
Expand Down Expand Up @@ -204,7 +205,7 @@ const completeDocketEntryQC = async (
sentByUserId: user.userId,
});

await saveWorkItem(workItemToUpdate.validate().toRawObject());
await saveWorkItem({ workItem: workItemToUpdate.validate().toRawObject() });

let servedParties = aggregatePartiesForService(caseEntity);
let paperServicePdfUrl;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -28,12 +28,11 @@ export const petitionsClerkAssignsWorkItemToSelf = cerebralTest => {
await cerebralTest.runSequence('selectWorkItemSequence', {
workItem: unassignedWorkItem,
});

const selectedWorkItems = cerebralTest.getState('selectedWorkItems');
expect(selectedWorkItems.length).toEqual(1);
cerebralTest.selectedWorkItem = selectedWorkItems[0];
expect(unassignedWorkItem).toMatchObject({
assigneeId: null,
});
expect(unassignedWorkItem.assigneId).not.toBeDefined();

// select an assignee
expect(cerebralTest.getState('assigneeId')).toBeNull();
Expand Down

0 comments on commit c16b3b4

Please sign in to comment.