Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
27 commits
Select commit Hold shift + click to select a range
382130c
NFDIV-5132 - Draft changes for general Gen-Apps (#4615)
pallavijustice Feb 27, 2026
6f1a75e
NFDIV-5133 - LiP D11 Gen App journey - Part2 (#4616)
pallavijustice Mar 4, 2026
cd8a802
Merge branch 'master' into lip-digitised-general-applications
adamg-hmcts Mar 12, 2026
6843675
Linter correction
adamg-hmcts Mar 12, 2026
b8f50fc
More linter corrections
adamg-hmcts Mar 12, 2026
97bf01c
Merge branch 'master' into lip-digitised-general-applications
adamg-hmcts Mar 12, 2026
d98ac38
[NFDIV-5178] D11 general application payment journey (#4632)
adamg-hmcts Mar 13, 2026
293cc38
Update backend PR references
adamg-hmcts Mar 13, 2026
c80b4ae
Reduce duplication in payment post controllers
adamg-hmcts Mar 13, 2026
ca01a7d
Linter corrections
adamg-hmcts Mar 13, 2026
79cd5ff
NFDIV-5135 - Joint applicant1 d11 gen app journey (#4670)
pallavijustice Mar 13, 2026
8928207
NFDIV-5425 - Changes (#4668)
pallavijustice Mar 13, 2026
bafa6d2
NFDIV-5235 D11 landing page conditional content (#4657)
pallavijustice Mar 13, 2026
d8b1a0b
Add default gen app download link text
adamg-hmcts Mar 13, 2026
61e1302
Linter corrections
adamg-hmcts Mar 13, 2026
3efc475
NFDIV-5235 Update withdraw title
pallavijustice Mar 16, 2026
32064cf
Merge branch 'master' into lip-digitised-general-applications
adamg-hmcts Mar 17, 2026
54c42af
[NFDIV-5136] Applicant 2 general application journey (#4672)
adamg-hmcts Mar 18, 2026
c8b6a8c
NFDIV-5047 - Allow citizen to withdraw unpaid D11 general application…
pallavijustice Mar 18, 2026
c0cdabf
[NFDIV-5185] D11 General Applications Save and Sign Out (#4682)
adamg-hmcts Mar 19, 2026
bdbe88f
[NFDIV-5186] Joint gen apps save sign out (#4690)
adamg-hmcts Mar 19, 2026
052f1d3
[NFDIV-5424] Search gov backwards compatibility (#4685)
adamg-hmcts Mar 20, 2026
e430ec6
NFDIV-5135 - Fix issue with CYA page.
pallavijustice Mar 25, 2026
ace7aed
NFDIV-5235-Update content for Amend section on D11 and revise the app…
pallavijustice Mar 27, 2026
438d961
Resolve conflicts by accepting welsh hub link text
adamg-hmcts Mar 31, 2026
7516d47
[NFDIV-5447] Joint general application label (#4720)
adamg-hmcts Apr 2, 2026
cdfd507
[NFDIV-5441] Update D11 Landing Page Guidance (#4719)
adamg-hmcts Apr 2, 2026
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion Jenkinsfile_CNP
Original file line number Diff line number Diff line change
Expand Up @@ -73,6 +73,6 @@ withPipeline(type, product, component) {

// uncomment to connect backend PR
//onPR {
// env.CASE_TYPE="NFD-4798"
env.CASE_TYPE="NFD-4970"
//}
}
2 changes: 1 addition & 1 deletion charts/nfdiv-frontend/values.preview.template.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ nodejs:
enabled: false
environment:
IDAM_TOKEN_CACHE: true
# CASE_TYPE: NFD-4798 # Uncomment to connect to backend PR, don't forget Jenkinsfile_CNP too
CASE_TYPE: NFD-4970 # Uncomment to connect to backend PR, don't forget Jenkinsfile_CNP too
keyVaults:
nfdiv:
resourceGroup: nfdiv
Expand Down
4 changes: 3 additions & 1 deletion config/default.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,8 @@ fees:
updateApplication: DivorceAmendPetition
finalOrderApplicationFee: GAOnNotice
searchDecreeNisiOrFinalOrder: SearchIndexDivCentral
generalAppWithoutHearing: GeneralAppWithoutNotice
generalAppWithHearing: GAOnNotice
services:
authProvider:
url: 'http://rpe-service-auth-provider-aat.service.core-compute-aat.internal'
Expand Down Expand Up @@ -127,4 +129,4 @@ govukUrls:
getHelpWithCourtFeesCY: 'https://www.gov.uk/help-i-dalu-ffioedd-llysoedd-a-thribiwnlysoedd'
certifiedTranslation: 'https://www.gov.uk/certifying-a-document#certifying-a-translation'
searchForDecreeAbsoluteOrFinalOrder: 'https://www.gov.uk/copy-decree-absolute-final-order/do-not-know-which-court'
serviceOfDocuments: 'https://www.gov.uk/guidance/service-of-documents-and-taking-of-evidence'
serviceOfDocuments: 'https://www.gov.uk/guidance/service-of-documents-and-taking-of-evidence'
56 changes: 56 additions & 0 deletions src/main/app/case/case.ts
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,8 @@ import {
FinancialOrderFor,
Gender,
GeneralApplication,
GeneralApplicationHearingNotRequired,
GeneralApplicationType,
InterimApplicationType,
JurisdictionConnections,
LegalAdvisorDecision,
Expand Down Expand Up @@ -211,6 +213,8 @@ export const formFieldsToCaseMapping: Partial<Record<keyof Case, keyof CaseData>
serviceApplicationAnswers: 'serviceApplicationAnswers',
applicant1InterimApplicationType: 'applicant1InterimApplicationType',
applicant1InterimAppsStatementOfTruth: 'applicant1InterimAppsStatementOfTruth',
applicant2InterimApplicationType: 'applicant2InterimApplicationType',
applicant2InterimAppsStatementOfTruth: 'applicant2InterimAppsStatementOfTruth',
applicant1NoResponseOwnSearches: 'applicant1NoResponseOwnSearches',
applicant1NoResponseRespondentAddressInEnglandWales: 'applicant1NoResponseRespondentAddressInEnglandWales',
applicant1NoResponsePartnerInUkOrReceivingBenefits: 'applicant1NoResponsePartnerInUkOrReceivingBenefits',
Expand All @@ -231,6 +235,13 @@ export const formFieldsToCaseMapping: Partial<Record<keyof Case, keyof CaseData>
applicant1InterimAppsHwfRefNumber: 'applicant1InterimAppsHwfRefNumber',
applicant1InterimAppsEvidenceDocs: 'applicant1InterimAppsEvidenceDocs',
applicant1InterimAppsCannotUploadDocs: 'applicant1InterimAppsCannotUploadDocs',
applicant2InterimAppsIUnderstand: 'applicant2InterimAppsIUnderstand',
applicant2InterimAppsUseHelpWithFees: 'applicant2InterimAppsUseHelpWithFees',
applicant2InterimAppsHaveHwfReference: 'applicant2InterimAppsHaveHwfReference',
applicant2InterimAppsCanUploadEvidence: 'applicant2InterimAppsCanUploadEvidence',
applicant2InterimAppsHwfRefNumber: 'applicant2InterimAppsHwfRefNumber',
applicant2InterimAppsEvidenceDocs: 'applicant2InterimAppsEvidenceDocs',
applicant2InterimAppsCannotUploadDocs: 'applicant2InterimAppsCannotUploadDocs',
applicant1DeemedEvidenceDetails: 'applicant1DeemedEvidenceDetails',
applicant1DeemedNoEvidenceStatement: 'applicant1DeemedNoEvidenceStatement',
applicant1BailiffPartnersName: 'applicant1BailiffPartnersName',
Expand Down Expand Up @@ -306,6 +317,7 @@ export const formFieldsToCaseMapping: Partial<Record<keyof Case, keyof CaseData>
applicant1SearchGovRecordsPartnerAdditionalAddress2: 'applicant1SearchGovRecordsPartnerAdditionalAddress2',
applicant1SearchGovRecordsPartnerAdditionalAddressDates2: 'applicant1SearchGovRecordsPartnerAdditionalAddressDates2',
generalApplications: 'generalApplications',
generalReferralType: 'generalReferralType',
applicant1GeneralAppServiceRequest: 'applicant1GeneralAppServiceRequest',
applicant2GeneralAppServiceRequest: 'applicant2GeneralAppServiceRequest',
applicant1GeneralAppPayments: 'applicant1GeneralAppPayments',
Expand Down Expand Up @@ -355,6 +367,22 @@ export const formFieldsToCaseMapping: Partial<Record<keyof Case, keyof CaseData>
withdrawApplicationReason: 'withdrawApplicationReason',
applicant2ConfirmWithdrawApplication: 'applicant2ConfirmWithdrawApplication',
applicant2WithdrawApplicationReason: 'applicant2WithdrawApplicationReason',
applicant1GenAppCannotUploadAgreedEvidence: 'applicant1GenAppCannotUploadAgreedEvidence',
applicant1GenAppHearingNotRequired: 'applicant1GenAppHearingNotRequired',
applicant1GenAppPartnerAgreesDocs: 'applicant1GenAppPartnerAgreesDocs',
applicant1GenAppPartnerDetailsCorrect: 'applicant1GenAppPartnerDetailsCorrect',
applicant1GenAppReason: 'applicant1GenAppReason',
applicant1GenAppStatementOfEvidence: 'applicant1GenAppStatementOfEvidence',
applicant1GenAppType: 'applicant1GenAppType',
applicant1GenAppTypeOtherDetails: 'applicant1GenAppTypeOtherDetails',
applicant2GenAppCannotUploadAgreedEvidence: 'applicant2GenAppCannotUploadAgreedEvidence',
applicant2GenAppHearingNotRequired: 'applicant2GenAppHearingNotRequired',
applicant2GenAppPartnerAgreesDocs: 'applicant2GenAppPartnerAgreesDocs',
applicant2GenAppPartnerDetailsCorrect: 'applicant2GenAppPartnerDetailsCorrect',
applicant2GenAppReason: 'applicant2GenAppReason',
applicant2GenAppStatementOfEvidence: 'applicant2GenAppStatementOfEvidence',
applicant2GenAppType: 'applicant2GenAppType',
applicant2GenAppTypeOtherDetails: 'applicant2GenAppTypeOtherDetails',
};

export function formatCase<OutputFormat>(fields: FieldFormats, data: Partial<Case> | CaseData): OutputFormat {
Expand Down Expand Up @@ -629,6 +657,14 @@ export interface Case {
applicant1InterimAppsEvidenceUploadedFiles?: UploadedFile[];
applicant1InterimAppsEvidenceDocs?: ListValue<Partial<DivorceDocument> | null>[];
applicant1InterimAppsCannotUploadDocs?: Checkbox;
applicant2InterimAppsIUnderstand?: Checkbox;
applicant2InterimAppsUseHelpWithFees?: YesOrNo;
applicant2InterimAppsHaveHwfReference?: YesOrNo;
applicant2InterimAppsCanUploadEvidence?: YesOrNo;
applicant2InterimAppsHwfRefNumber?: string;
applicant2InterimAppsEvidenceUploadedFiles?: UploadedFile[];
applicant2InterimAppsEvidenceDocs?: ListValue<Partial<DivorceDocument> | null>[];
applicant2InterimAppsCannotUploadDocs?: Checkbox;
applicant1DeemedEvidenceDetails?: string;
applicant1DeemedNoEvidenceStatement?: string;
applicant1BailiffPartnerInARefuge: YesOrNoOrNotKnown;
Expand Down Expand Up @@ -666,6 +702,7 @@ export interface Case {
applicant1InterimApplicationType?: InterimApplicationType;
applicant2InterimApplicationType?: InterimApplicationType;
applicant1InterimAppsStatementOfTruth?: Checkbox;
applicant2InterimAppsStatementOfTruth?: Checkbox;
applicant1NoResponseOwnSearches?: NoResponseOwnSearches;
applicant1NoResponseRespondentAddressInEnglandWales?: Checkbox;
applicant1NoResponsePartnerInUkOrReceivingBenefits?: YesOrNo;
Expand Down Expand Up @@ -724,6 +761,7 @@ export interface Case {
applicant1SearchGovRecordsPartnerAdditionalAddress2?: string;
applicant1SearchGovRecordsPartnerAdditionalAddressDates2?: string;
generalApplications?: ListValue<GeneralApplication>[];
generalReferralType?: string;
applicant1GeneralAppServiceRequest?: string;
applicant2GeneralAppServiceRequest?: string;
applicant1GeneralAppPayments?: ListValue<Payment>[];
Expand Down Expand Up @@ -789,6 +827,24 @@ export interface Case {
withdrawApplicationReason?: string;
applicant2ConfirmWithdrawApplication?: YesOrNo;
applicant2WithdrawApplicationReason?: string;
applicant1GenAppCannotUploadAgreedEvidence?: Checkbox;
applicant1GenAppHearingNotRequired?: GeneralApplicationHearingNotRequired;
applicant1GenAppPartnerAgreesDocs?: ListValue<Partial<DivorceDocument> | null>[];
applicant1GenAppPartnerAgreesUploadedFiles?: UploadedFile[];
applicant1GenAppPartnerDetailsCorrect?: YesOrNo;
applicant1GenAppReason?: string;
applicant1GenAppStatementOfEvidence?: string;
applicant1GenAppType?: GeneralApplicationType | null;
applicant1GenAppTypeOtherDetails?: string;
applicant2GenAppCannotUploadAgreedEvidence?: Checkbox;
applicant2GenAppHearingNotRequired?: GeneralApplicationHearingNotRequired;
applicant2GenAppPartnerAgreesDocs?: ListValue<Partial<DivorceDocument> | null>[];
applicant2GenAppPartnerAgreesUploadedFiles?: UploadedFile[];
applicant2GenAppPartnerDetailsCorrect?: YesOrNo;
applicant2GenAppReason?: string;
applicant2GenAppStatementOfEvidence?: string;
applicant2GenAppType?: GeneralApplicationType | null;
applicant2GenAppTypeOtherDetails?: string;
}

export interface CaseWithId extends Case {
Expand Down
52 changes: 44 additions & 8 deletions src/main/app/case/definition.ts
Original file line number Diff line number Diff line change
Expand Up @@ -527,9 +527,9 @@ export interface CaseData {
applicant1NameDifferentToMarriageCertificateMethod: ChangedNameHow[];
applicant1NameDifferentToMarriageCertificateOtherDetails: string;
applicant1WhyNameDifferent: ChangedNameWhy[];
applicant1WhyNameDifferentOtherDetails: string,
applicant1WhyNameDifferentOtherDetails: string;
applicant2WhyNameDifferent: ChangedNameWhy[];
applicant2WhyNameDifferentOtherDetails: string,
applicant2WhyNameDifferentOtherDetails: string;
applicant1NameChangedHow: ChangedNameHow[];
applicant1NameChangedHowOtherDetails: string;
applicant1Address: AddressGlobalUK;
Expand Down Expand Up @@ -964,7 +964,7 @@ export interface CaseData {
alternativeServiceFeeRequired: YesOrNo;
serviceApplicationAnswers: DivorceDocument;
servicePayments: ListValue<Payment>[];
serviceApplicationSubmittedOnline: YesOrNo,
serviceApplicationSubmittedOnline: YesOrNo;
servicePaymentFeePaymentMethod: ServicePaymentMethod;
servicePaymentFeeAccountNumber: string;
servicePaymentFeeDateOfPayment: DateAsString;
Expand Down Expand Up @@ -1068,6 +1068,13 @@ export interface CaseData {
applicant1InterimAppsHwfRefNumber: string;
applicant1InterimAppsEvidenceDocs: ListValue<DivorceDocument>[];
applicant1InterimAppsCannotUploadDocs: YesOrNo;
applicant2InterimAppsIUnderstand: YesOrNo;
applicant2InterimAppsUseHelpWithFees: YesOrNo;
applicant2InterimAppsHaveHwfReference: YesOrNo;
applicant2InterimAppsCanUploadEvidence: YesOrNo;
applicant2InterimAppsHwfRefNumber: string;
applicant2InterimAppsEvidenceDocs: ListValue<DivorceDocument>[];
applicant2InterimAppsCannotUploadDocs: YesOrNo;
applicant1DeemedEvidenceDetails: string;
applicant1DeemedNoEvidenceStatement: string;
applicant1BailiffPartnersName: string;
Expand Down Expand Up @@ -1105,6 +1112,7 @@ export interface CaseData {
applicant1InterimApplicationType: InterimApplicationType;
applicant2InterimApplicationType: InterimApplicationType;
applicant1InterimAppsStatementOfTruth: YesOrNo;
applicant2InterimAppsStatementOfTruth: YesOrNo;
applicant1NoResponsePartnerAddress: AddressGlobalUK;
applicant1NoResponsePartnerAddressOverseas: YesOrNo;
applicant1NoResponsePartnerEmailAddress: string;
Expand Down Expand Up @@ -1151,7 +1159,7 @@ export interface CaseData {
applicant1DispensePartnerLastSeenOver2YearsAgo: YesOrNo;
applicant1DispensePartnerLastSeenDescription: string;
applicant1DispenseHavePartnerEmailAddresses: YesOrNo;
applicant1DispenseHaveSearchedFinalOrder: YesOrNo
applicant1DispenseHaveSearchedFinalOrder: YesOrNo;
applicant1DispenseWhyNoFinalOrderSearch: string;
applicant1DispensePartnerEmailAddresses: string;
applicant1DispenseHavePartnerPhoneNumbers: YesOrNo;
Expand Down Expand Up @@ -1183,6 +1191,22 @@ export interface CaseData {
withdrawApplicationReason: string;
applicant2ConfirmWithdrawApplication: YesOrNo;
applicant2WithdrawApplicationReason: string;
applicant1GenAppCannotUploadAgreedEvidence: YesOrNo;
applicant1GenAppHearingNotRequired: GeneralApplicationHearingNotRequired;
applicant1GenAppPartnerAgreesDocs: ListValue<DivorceDocument>[];
applicant1GenAppPartnerDetailsCorrect: YesOrNo;
applicant1GenAppReason: string;
applicant1GenAppStatementOfEvidence: string;
applicant1GenAppType: GeneralApplicationType;
applicant1GenAppTypeOtherDetails: string;
applicant2GenAppCannotUploadAgreedEvidence: YesOrNo;
applicant2GenAppHearingNotRequired: GeneralApplicationHearingNotRequired;
applicant2GenAppPartnerAgreesDocs: ListValue<DivorceDocument>[];
applicant2GenAppPartnerDetailsCorrect: YesOrNo;
applicant2GenAppReason: string;
applicant2GenAppStatementOfEvidence: string;
applicant2GenAppType: GeneralApplicationType;
applicant2GenAppTypeOtherDetails: string;
}

export interface CaseDocuments {
Expand Down Expand Up @@ -1532,6 +1556,7 @@ export interface GeneralApplication {
generalApplicationSubmittedOnline?: string;
generalApplicationReceivedDate?: DateAsString;
generalApplicationDocsUploadedPreSubmission?: YesOrNo;
generalApplicationFeeHasCompletedOnlinePayment?: YesOrNo;
}

export interface GeneralEmail {
Expand Down Expand Up @@ -2098,6 +2123,7 @@ export const enum InterimApplicationType {
BAILIFF_SERVICE = 'bailiffService',
SEARCH_GOV_RECORDS = 'searchGovRecords',
PROCESS_SERVER_SERVICE = 'processServerService',
DIGITISED_GENERAL_APPLICATION_D11 = 'digitisedGeneralApplicationD11',
}

export const enum SearchGovRecordsWhichDepartment {
Expand All @@ -2115,6 +2141,10 @@ export const enum GeneralApplicationType {
OTHER = 'other',
BAILIFF_SERVICE = 'bailiffService',
SEARCH_GOV_RECORDS = 'disclosureViaDwp',
WITHDRAW_POST_ISSUE = 'withdrawPostIssue',
DELAY = 'delay',
EXTEND = 'extend',
AMEND_APPLICATION = 'amendApplication',
}

export const enum GeneralOrderDivorceParties {
Expand All @@ -2134,6 +2164,7 @@ export const enum GeneralOrderJudgeOrLegalAdvisorType {

export const enum GeneralParties {
APPLICANT = 'applicant',
APPLICANT2 = 'applicant2',
RESPONDENT = 'respondent',
OTHER = 'other',
}
Expand Down Expand Up @@ -2170,6 +2201,13 @@ export const enum JudgeCostsClaimGranted {
ADJOURN = 'Adjourn',
}

export const enum GeneralApplicationHearingNotRequired {
YES_PARTNER_AGREES_WITH_APPLICATION = 'yesPartnerAgreesWithApplication',
YES_PARTNER_AGREES_WITH_NO_HEARING = 'yesPartnerAgreesWithNoHearing',
YES_DOES_NOT_NEED_CONSENT = 'yesDoesNotNeedConsent',
NO = 'no',
}

/**
* Values:
* - `A` - APP_1_APP_2_RESIDENT
Expand Down Expand Up @@ -2347,6 +2385,7 @@ export const enum State {
AwaitingFinalOrder = 'AwaitingFinalOrder',
AwaitingGeneralConsideration = 'AwaitingGeneralConsideration',
AwaitingGeneralReferralPayment = 'AwaitingGeneralReferralPayment',
AwaitingGenAppDocuments = 'AwaitingGenAppDocuments',
AwaitingGenAppHWFEvidence = 'AwaitingGenAppHWFEvidence',
AwaitingGenAppHWFPartPayment = 'AwaitingGenAppHWFPartPayment',
AwaitingHWFDecision = 'AwaitingHWFDecision',
Expand Down Expand Up @@ -2405,10 +2444,6 @@ export const FINAL_ORDER_PAYMENT_STATES: Set<State> = new Set([State.AwaitingFin

export const SERVICE_PAYMENT_STATES: Set<State> = new Set([State.AwaitingServicePayment]);

export const GENERAL_APPLICATION_PAYMENT_STATES: Set<State> = new Set([
State.AwaitingGeneralApplicationPayment
]);

export const enum SupplementaryCaseType {
NA = 'notApplicable',
JUDICIAL_SEPARATION = 'judicialSeparation',
Expand Down Expand Up @@ -3024,6 +3059,7 @@ export const SYSTEM_LINK_WITH_BULK_CASE = 'system-link-with-bulk-case';
export const SYSTEM_ISSUE_SOLICITOR_SERVICE_PACK = 'system-issue-solicitor-service-pack';
export const CITIZEN_WITHDRAWN = 'citizen-withdrawn';
export const WITHDRAW_SERVICE_APPLICATION = 'service-application-withdrawn';
export const WITHDRAW_D11_APPLICATION = 'general-application-withdrawn';
export const CASEWORKER_SYSTEM_USER_UPDATE_ISSUE_DATE = 'system-update-issue-date';
export const CASEWORKER_REQUEST_FOR_INFORMATION = 'caseworker-request-for-information';
export const CASEWORKER_ISSUE_APPLICATION = 'caseworker-issue-application';
Expand Down
13 changes: 13 additions & 0 deletions src/main/app/case/formatter/uploaded-files.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -60,6 +60,19 @@ describe('uploadedFilesFromApiApplicant1', () => {
expect(result.applicant1InterimAppsEvidenceUploadedFiles?.[0].id).toBe('1');
expect(result.applicant1InterimAppsEvidenceUploadedFiles?.[1].id).toBe('2');
});

it('converts general application partner agrees evidence documents', async () => {
const result = fromApiApplicant1({
applicant1GenAppPartnerAgreesDocs: [
{ id: '1', value: { documentFileName: 'filename' } as DivorceDocument },
{ id: '2', value: { documentFileName: 'filename' } as DivorceDocument },
],
});

expect(result.applicant1GenAppPartnerAgreesUploadedFiles?.length).toBe(2);
expect(result.applicant1GenAppPartnerAgreesUploadedFiles?.[0].id).toBe('1');
expect(result.applicant1GenAppPartnerAgreesUploadedFiles?.[1].id).toBe('2');
});
});

describe('uploadedFilesFromApiApplicant2', () => {
Expand Down
18 changes: 18 additions & 0 deletions src/main/app/case/formatter/uploaded-files.ts
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,12 @@ export const fromApiApplicant1 = (data: Partial<CaseData>): Partial<Case> => ({
id: `${file.id}`,
name: `${getFilename(file.value)}`,
})) || [],
applicant1GenAppPartnerAgreesDocs: data.applicant1GenAppPartnerAgreesDocs,
applicant1GenAppPartnerAgreesUploadedFiles:
data.applicant1GenAppPartnerAgreesDocs?.map(file => ({
id: `${file.id}`,
name: `${getFilename(file.value)}`,
})) || [],
});

export const fromApiApplicant2 = (data: Partial<CaseData>): Partial<Case> => ({
Expand All @@ -53,6 +59,18 @@ export const fromApiApplicant2 = (data: Partial<CaseData>): Partial<Case> => ({
name: `${getFilename(file.value)}`,
})) || [],
applicant2UnableToUploadEvidence: checkboxConverter(data.applicant2UnableToUploadEvidence),
applicant2InterimAppsEvidenceDocs: data.applicant2InterimAppsEvidenceDocs,
applicant2InterimAppsEvidenceUploadedFiles:
data.applicant2InterimAppsEvidenceDocs?.map(file => ({
id: `${file.id}`,
name: `${getFilename(file.value)}`,
})) || [],
applicant2GenAppPartnerAgreesDocs: data.applicant2GenAppPartnerAgreesDocs,
applicant2GenAppPartnerAgreesUploadedFiles:
data.applicant2GenAppPartnerAgreesDocs?.map(file => ({
id: `${file.id}`,
name: `${getFilename(file.value)}`,
})) || [],
});

export const getFilename = (document: Partial<DivorceDocument> | undefined | null): string | undefined => {
Expand Down
Loading